Skip to content

Commit

Permalink
fix(align-deps): add profile for 0.74
Browse files Browse the repository at this point in the history
  • Loading branch information
tido64 committed Mar 18, 2024
1 parent 402cb2c commit abf7913
Show file tree
Hide file tree
Showing 9 changed files with 186 additions and 52 deletions.
5 changes: 5 additions & 0 deletions .changeset/forty-peas-change.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@rnx-kit/align-deps": patch
---

Added profile for react-native 0.74
98 changes: 49 additions & 49 deletions packages/align-deps/README.md

Large diffs are not rendered by default.

4 changes: 4 additions & 0 deletions packages/align-deps/scripts/update-profile.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -470,11 +470,15 @@ async function main({

const ignoredCapabilities = [
"babel-preset-react-native",
"community/cli",
"community/cli-android",
"community/cli-ios",
"core",
"core-android",
"core-ios",
"core-macos",
"core-windows",
"core/metro-config",
"hermes",
"metro",
"metro-config",
Expand Down
2 changes: 2 additions & 0 deletions packages/align-deps/src/presets/microsoft/react-native.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ import { profile as profile_0_70 } from "./react-native/profile-0.70";
import { profile as profile_0_71 } from "./react-native/profile-0.71";
import { profile as profile_0_72 } from "./react-native/profile-0.72";
import { profile as profile_0_73 } from "./react-native/profile-0.73";
import { profile as profile_0_74 } from "./react-native/profile-0.74";

// Also export this by name for scripts to work around a bug where this module
// is wrapped twice, i.e. `{ default: { default: preset } }`, when imported as
Expand All @@ -30,4 +31,5 @@ export const preset: Readonly<Preset> = {
"0.71": profile_0_71,
"0.72": profile_0_72,
"0.73": profile_0_73,
"0.74": profile_0_74,
};
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,11 @@ export const profile: Profile = {
name: "@react-native-masked-view/masked-view",
version: "^0.3.0",
},
"navigation/stack": {
name: "@react-navigation/stack",
version: "^6.3.21",
capabilities: ["navigation/native"],
},
netinfo: {
name: "@react-native-community/netinfo",
version: "^11.0.1",
Expand Down Expand Up @@ -135,6 +140,6 @@ export const profile: Profile = {
},
webview: {
name: "react-native-webview",
version: "^13.6.1",
version: "^13.7.2",
},
};
115 changes: 115 additions & 0 deletions packages/align-deps/src/presets/microsoft/react-native/profile-0.74.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,115 @@
import type { Package, Profile } from "../../../types";
import { profile as profile_0_73 } from "./profile-0.73";

const reactNative: Package = {
name: "react-native",
version: "^0.74.0",
capabilities: ["react", "core/metro-config"],
};

export const profile: Profile = {
...profile_0_73,
react: {
name: "react",
version: "18.2.0",
},
"react-dom": {
name: "react-dom",
version: "^18.2.0",
capabilities: ["react"],
},
"react-test-renderer": {
name: "react-test-renderer",
version: "18.2.0",
capabilities: ["react"],
devOnly: true,
},

core: reactNative,
"core-android": reactNative,
"core-ios": reactNative,
"core-macos": {
name: "react-native-macos",
version: "^0.74.0",
capabilities: ["react"],
},
"core-windows": {
name: "react-native-windows",
version: "^0.74.0",
capabilities: ["core"],
},
"core/metro-config": {
name: "@react-native/metro-config",
version: "^0.74.0",
devOnly: true,
},

"babel-preset-react-native": {
name: "@react-native/babel-preset",
version: "^0.74.0",
devOnly: true,
},
"community/cli": {
name: "@react-native-community/cli",
version: "^13.6.1",
capabilities: ["community/cli-android", "community/cli-ios"],
devOnly: true,
},
"community/cli-android": {
name: "@react-native-community/cli-platform-android",
version: "^13.6.1",
devOnly: true,
},
"community/cli-ios": {
name: "@react-native-community/cli-platform-ios",
version: "^13.6.1",
devOnly: true,
},
metro: {
name: "metro",
version: "^0.80.3",
devOnly: true,
},
"metro-config": {
name: "metro-config",
version: "^0.80.3",
devOnly: true,
},
"metro-core": {
name: "metro-core",
version: "^0.80.3",
devOnly: true,
},
"metro-react-native-babel-transformer": {
name: "@react-native/metro-babel-transformer",
version: "^0.74.0",
devOnly: true,
},
"metro-resolver": {
name: "metro-resolver",
version: "^0.80.3",
devOnly: true,
},
"metro-runtime": {
name: "metro-runtime",
version: "^0.80.3",
devOnly: true,
},

netinfo: {
name: "@react-native-community/netinfo",
version: "^11.3.1",
},
storage: {
name: "@react-native-async-storage/async-storage",
version: "^1.22.3",
},
svg: {
name: "react-native-svg",
version: "^15.2.0",
},
"test-app": {
name: "react-native-test-app",
version: "^3.3.6",
},
};
3 changes: 3 additions & 0 deletions packages/align-deps/test/preset.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import { profile as profile_0_70 } from "../src/presets/microsoft/react-native/p
import { profile as profile_0_71 } from "../src/presets/microsoft/react-native/profile-0.71";
import { profile as profile_0_72 } from "../src/presets/microsoft/react-native/profile-0.72";
import { profile as profile_0_73 } from "../src/presets/microsoft/react-native/profile-0.73";
import { profile as profile_0_74 } from "../src/presets/microsoft/react-native/profile-0.74";

describe("filterPreset()", () => {
test("returns no profiles if requirements cannot be satisfied", () => {
Expand Down Expand Up @@ -35,6 +36,7 @@ describe("filterPreset()", () => {
"0.71": profile_0_71,
"0.72": profile_0_72,
"0.73": profile_0_73,
"0.74": profile_0_74,
});
});

Expand All @@ -46,6 +48,7 @@ describe("filterPreset()", () => {
"0.71": profile_0_71,
"0.72": profile_0_72,
"0.73": profile_0_73,
"0.74": profile_0_74,
});
});

Expand Down
2 changes: 1 addition & 1 deletion packages/react-native-auth/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
},
"peerDependencies": {
"react": "16.11.0 || 16.13.1 || 17.0.1 || 17.0.2 || 18.0.0 || 18.1.0 || 18.2.0",
"react-native": "^0.62.3 || ^0.63.2 || ^0.64.2 || ^0.65.0 || ^0.66.0 || ^0.67.0 || ^0.68.0 || ^0.69.0 || ^0.70.0 || ^0.71.0 || ^0.72.0 || ^0.73.0"
"react-native": "^0.62.3 || ^0.63.2 || ^0.64.2 || ^0.65.0 || ^0.66.0 || ^0.67.0 || ^0.68.0 || ^0.69.0 || ^0.70.0 || ^0.71.0 || ^0.72.0 || ^0.73.0 || ^0.74.0"
},
"devDependencies": {
"@babel/core": "^7.20.0",
Expand Down
2 changes: 1 addition & 1 deletion yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -4225,7 +4225,7 @@ __metadata:
typescript: "npm:^5.0.0"
peerDependencies:
react: 16.11.0 || 16.13.1 || 17.0.1 || 17.0.2 || 18.0.0 || 18.1.0 || 18.2.0
react-native: ^0.62.3 || ^0.63.2 || ^0.64.2 || ^0.65.0 || ^0.66.0 || ^0.67.0 || ^0.68.0 || ^0.69.0 || ^0.70.0 || ^0.71.0 || ^0.72.0 || ^0.73.0
react-native: ^0.62.3 || ^0.63.2 || ^0.64.2 || ^0.65.0 || ^0.66.0 || ^0.67.0 || ^0.68.0 || ^0.69.0 || ^0.70.0 || ^0.71.0 || ^0.72.0 || ^0.73.0 || ^0.74.0
languageName: unknown
linkType: soft

Expand Down

0 comments on commit abf7913

Please sign in to comment.