react-native 0.81.3 → 0.81.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Libraries/Core/ReactNativeVersion.js +1 -1
- package/React/Base/RCTVersion.m +1 -1
- package/ReactAndroid/gradle.properties +1 -1
- package/ReactAndroid/src/main/java/com/facebook/react/modules/systeminfo/ReactNativeVersion.kt +1 -1
- package/ReactCommon/cxxreact/ReactNativeVersion.h +2 -2
- package/package.json +8 -8
- package/scripts/cocoapods/autolinking.rb +6 -0
- package/scripts/cocoapods/codegen_utils.rb +1 -1
- package/scripts/codegen/generate-artifacts-executor/index.js +5 -6
- package/scripts/codegen/generate-artifacts-executor/utils.js +41 -10
- package/sdks/hermesc/osx-bin/hermes +0 -0
- package/sdks/hermesc/osx-bin/hermesc +0 -0
- package/sdks/hermesc/win64-bin/hermesc.exe +0 -0
package/React/Base/RCTVersion.m
CHANGED
|
@@ -14,14 +14,14 @@
|
|
|
14
14
|
|
|
15
15
|
#define REACT_NATIVE_VERSION_MAJOR 0
|
|
16
16
|
#define REACT_NATIVE_VERSION_MINOR 81
|
|
17
|
-
#define REACT_NATIVE_VERSION_PATCH
|
|
17
|
+
#define REACT_NATIVE_VERSION_PATCH 4
|
|
18
18
|
|
|
19
19
|
namespace facebook::react {
|
|
20
20
|
|
|
21
21
|
constexpr struct {
|
|
22
22
|
int32_t Major = 0;
|
|
23
23
|
int32_t Minor = 81;
|
|
24
|
-
int32_t Patch =
|
|
24
|
+
int32_t Patch = 4;
|
|
25
25
|
std::string_view Prerelease = "";
|
|
26
26
|
} ReactNativeVersion;
|
|
27
27
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "react-native",
|
|
3
|
-
"version": "0.81.
|
|
3
|
+
"version": "0.81.4",
|
|
4
4
|
"description": "A framework for building native apps using React",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": {
|
|
@@ -162,13 +162,13 @@
|
|
|
162
162
|
},
|
|
163
163
|
"dependencies": {
|
|
164
164
|
"@jest/create-cache-key-function": "^29.7.0",
|
|
165
|
-
"@react-native/assets-registry": "0.81.
|
|
166
|
-
"@react-native/codegen": "0.81.
|
|
167
|
-
"@react-native/community-cli-plugin": "0.81.
|
|
168
|
-
"@react-native/gradle-plugin": "0.81.
|
|
169
|
-
"@react-native/js-polyfills": "0.81.
|
|
170
|
-
"@react-native/normalize-colors": "0.81.
|
|
171
|
-
"@react-native/virtualized-lists": "0.81.
|
|
165
|
+
"@react-native/assets-registry": "0.81.4",
|
|
166
|
+
"@react-native/codegen": "0.81.4",
|
|
167
|
+
"@react-native/community-cli-plugin": "0.81.4",
|
|
168
|
+
"@react-native/gradle-plugin": "0.81.4",
|
|
169
|
+
"@react-native/js-polyfills": "0.81.4",
|
|
170
|
+
"@react-native/normalize-colors": "0.81.4",
|
|
171
|
+
"@react-native/virtualized-lists": "0.81.4",
|
|
172
172
|
"abort-controller": "^3.0.0",
|
|
173
173
|
"anser": "^1.4.9",
|
|
174
174
|
"ansi-regex": "^5.0.0",
|
|
@@ -40,6 +40,12 @@ def list_native_modules!(config_command)
|
|
|
40
40
|
packages = config["dependencies"]
|
|
41
41
|
ios_project_root = Pathname.new(config["project"]["ios"]["sourceDir"])
|
|
42
42
|
react_native_path = Pathname.new(config["reactNativePath"])
|
|
43
|
+
codegen_output_path = ios_project_root.join("build/generated/autolinking/autolinking.json")
|
|
44
|
+
|
|
45
|
+
# Write autolinking react-native-config output to codegen folder
|
|
46
|
+
FileUtils.mkdir_p(File.dirname(codegen_output_path))
|
|
47
|
+
File.write(codegen_output_path, json)
|
|
48
|
+
|
|
43
49
|
found_pods = []
|
|
44
50
|
|
|
45
51
|
packages.each do |package_name, package|
|
|
@@ -87,7 +87,7 @@ class CodegenUtils
|
|
|
87
87
|
codegen_path = file_manager.join(ios_folder, codegen_dir)
|
|
88
88
|
return if !dir_manager.exist?(codegen_path)
|
|
89
89
|
|
|
90
|
-
FileUtils.rm_rf(
|
|
90
|
+
FileUtils.rm_rf("#{codegen_path}")
|
|
91
91
|
base_provider_path = file_manager.join(rn_path, 'React', 'Fabric', 'RCTThirdPartyFabricComponentsProvider')
|
|
92
92
|
FileUtils.rm_rf("#{base_provider_path}.h")
|
|
93
93
|
FileUtils.rm_rf("#{base_provider_path}.mm")
|
|
@@ -86,16 +86,19 @@ function execute(
|
|
|
86
86
|
buildCodegenIfNeeded();
|
|
87
87
|
}
|
|
88
88
|
|
|
89
|
-
const reactNativeConfig = readReactNativeConfig(
|
|
89
|
+
const reactNativeConfig = readReactNativeConfig(
|
|
90
|
+
projectRoot,
|
|
91
|
+
baseOutputPath,
|
|
92
|
+
);
|
|
90
93
|
const codegenEnabledLibraries = findCodegenEnabledLibraries(
|
|
91
94
|
pkgJson,
|
|
92
95
|
projectRoot,
|
|
96
|
+
baseOutputPath,
|
|
93
97
|
reactNativeConfig,
|
|
94
98
|
);
|
|
95
99
|
|
|
96
100
|
if (codegenEnabledLibraries.length === 0) {
|
|
97
101
|
codegenLog('No codegen-enabled libraries found.', true);
|
|
98
|
-
return;
|
|
99
102
|
}
|
|
100
103
|
|
|
101
104
|
let platforms =
|
|
@@ -110,10 +113,6 @@ function execute(
|
|
|
110
113
|
({name}) => !disabledLibraries.includes(name),
|
|
111
114
|
);
|
|
112
115
|
|
|
113
|
-
if (!libraries.length) {
|
|
114
|
-
continue;
|
|
115
|
-
}
|
|
116
|
-
|
|
117
116
|
const outputPath = computeOutputPath(
|
|
118
117
|
projectRoot,
|
|
119
118
|
baseOutputPath,
|
|
@@ -97,15 +97,40 @@ function cleanupEmptyFilesAndFolders(filepath /*: string */) {
|
|
|
97
97
|
}
|
|
98
98
|
}
|
|
99
99
|
|
|
100
|
-
function
|
|
101
|
-
|
|
100
|
+
function readGeneratedAutolinkingOutput(
|
|
101
|
+
baseOutputPath /*: string */,
|
|
102
|
+
) /*: $FlowFixMe */ {
|
|
103
|
+
// NOTE: Generated by scripts/cocoapods/autolinking.rb in list_native_modules (called by use_native_modules)
|
|
104
|
+
const autolinkingGeneratedPath = path.resolve(
|
|
105
|
+
baseOutputPath,
|
|
106
|
+
'build/generated/autolinking/autolinking.json',
|
|
107
|
+
);
|
|
108
|
+
if (fs.existsSync(autolinkingGeneratedPath)) {
|
|
109
|
+
// $FlowFixMe[unsupported-syntax]
|
|
110
|
+
return require(autolinkingGeneratedPath);
|
|
111
|
+
} else {
|
|
112
|
+
codegenLog(
|
|
113
|
+
`Could not find generated autolinking output at: ${autolinkingGeneratedPath}`,
|
|
114
|
+
);
|
|
115
|
+
return null;
|
|
116
|
+
}
|
|
117
|
+
}
|
|
102
118
|
|
|
103
|
-
|
|
119
|
+
function readReactNativeConfig(
|
|
120
|
+
projectRoot /*: string */,
|
|
121
|
+
baseOutputPath /*: string */,
|
|
122
|
+
) /*: $FlowFixMe */ {
|
|
123
|
+
const autolinkingOutput = readGeneratedAutolinkingOutput(baseOutputPath);
|
|
124
|
+
const rnConfigFilePath = path.resolve(projectRoot, 'react-native.config.js');
|
|
125
|
+
if (autolinkingOutput) {
|
|
126
|
+
return autolinkingOutput;
|
|
127
|
+
} else if (fs.existsSync(rnConfigFilePath)) {
|
|
128
|
+
// $FlowIgnore[unsupported-syntax]
|
|
129
|
+
return require(rnConfigFilePath);
|
|
130
|
+
} else {
|
|
131
|
+
codegenLog(`Could not find React Native config at: ${rnConfigFilePath}`);
|
|
104
132
|
return {};
|
|
105
133
|
}
|
|
106
|
-
|
|
107
|
-
// $FlowIgnore[unsupported-syntax]
|
|
108
|
-
return require(rnConfigFilePath);
|
|
109
134
|
}
|
|
110
135
|
|
|
111
136
|
/**
|
|
@@ -114,17 +139,23 @@ function readReactNativeConfig(projectRoot /*: string */) /*: $FlowFixMe */ {
|
|
|
114
139
|
function findCodegenEnabledLibraries(
|
|
115
140
|
pkgJson /*: $FlowFixMe */,
|
|
116
141
|
projectRoot /*: string */,
|
|
142
|
+
baseOutputPath /*: string */,
|
|
117
143
|
reactNativeConfig /*: $FlowFixMe */,
|
|
118
144
|
) /*: Array<$FlowFixMe> */ {
|
|
119
145
|
const projectLibraries = findProjectRootLibraries(pkgJson, projectRoot);
|
|
120
146
|
if (pkgJsonIncludesGeneratedCode(pkgJson)) {
|
|
121
147
|
return projectLibraries;
|
|
122
148
|
} else {
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
149
|
+
const libraries = [...projectLibraries];
|
|
150
|
+
// If we ran autolinking, we shouldn't try to run our own "autolinking-like"
|
|
151
|
+
// library discovery
|
|
152
|
+
if (!readGeneratedAutolinkingOutput(baseOutputPath)) {
|
|
153
|
+
libraries.push(...findExternalLibraries(pkgJson, projectRoot));
|
|
154
|
+
}
|
|
155
|
+
libraries.push(
|
|
126
156
|
...findLibrariesFromReactNativeConfig(projectRoot, reactNativeConfig),
|
|
127
|
-
|
|
157
|
+
);
|
|
158
|
+
return libraries;
|
|
128
159
|
}
|
|
129
160
|
}
|
|
130
161
|
|
|
Binary file
|
|
Binary file
|
|
Binary file
|