mirror of
https://github.com/react/react-native.git
synced 2026-09-29 16:58:04 +08:00
Improve types, fix translator compatibility for version-related modules (#42638)
Summary: Pull Request resolved: https://github.com/facebook/react-native/pull/42638 Enables these modules to be covered by `public-api-test`. - Standardise as CommonJS modules, fixing compatibility with [`flow-api-translator`](https://www.npmjs.com/package/flow-api-translator). - Use explicit object type in generated file template. Changelog: [Internal] Reviewed By: NickGerleman Differential Revision: D52963967 fbshipit-source-id: c9f3e35f70859c1b99b7297228ee2498f91d9041
This commit is contained in:
committed by
Facebook GitHub Bot
parent
0ea16fd3f7
commit
02e7244b3d
@@ -9,9 +9,16 @@
|
||||
* @flow strict
|
||||
*/
|
||||
|
||||
exports.version = {
|
||||
const version: $ReadOnly<{
|
||||
major: number,
|
||||
minor: number,
|
||||
patch: number,
|
||||
prerelease: string | null,
|
||||
}> = {
|
||||
major: ${major},
|
||||
minor: ${minor},
|
||||
patch: ${patch},
|
||||
prerelease: ${prerelease},
|
||||
};
|
||||
|
||||
module.exports = {version};
|
||||
|
||||
Reference in New Issue
Block a user