Skip to content

Commit 6cbfc54

Browse files
committed
bump deps + example move
1 parent 91b0e16 commit 6cbfc54

File tree

16 files changed

+3507
-665
lines changed

16 files changed

+3507
-665
lines changed

package.json

Lines changed: 4 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -21,30 +21,17 @@
2121
"turbo": "^1.12.5",
2222
"typescript": "^5.3.0"
2323
},
24+
"resolutions": {
25+
"@react-native-mac/virtualized-lists": "0.76.0"
26+
},
2427
"engines": {
2528
"node": "v20.11.1"
2629
},
2730
"packageManager": "[email protected]",
28-
"resolutions": {
29-
"@react-native-community/cli": "^14.0.0",
30-
"@react-native-community/cli-platform-android": "^14.0.0",
31-
"@react-native-community/cli-platform-ios": "^14.0.0",
32-
"@react-native/assets-registry": "^0.75.0",
33-
"@react-native/babel-plugin-codegen": "^0.75.0",
34-
"@react-native/babel-preset": "^0.75.0",
35-
"@react-native/codegen": "^0.75.0",
36-
"@react-native/community-cli-plugin": "^0.75.0",
37-
"@react-native/community-cli-plugin/@react-native-community/cli-server-api": "^14.0.0",
38-
"@react-native/community-cli-plugin/@react-native-community/cli-tools": "^14.0.0",
39-
"@react-native/gradle-plugin": "^0.75.0",
40-
"@react-native/js-polyfills": "^0.75.0",
41-
"@react-native/normalize-colors": "^0.75.0",
42-
"@react-native/virtualized-lists": "^0.75.0",
43-
"find-babel-config/json5": "^2.1.1"
44-
},
4531
"workspaces": [
4632
"packages/api",
4733
"packages/default-storage",
34+
"packages/default-storage/example",
4835
"packages/eslint-config",
4936
"packages/sqlite-storage",
5037
"packages/website"

packages/default-storage/example/app.json

Lines changed: 14 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,22 @@
33
"displayName": "AsyncStorageExample",
44
"components": [
55
{
6-
"appKey": "AsyncStorageExample"
6+
"appKey": "AsyncStorageExample",
7+
"displayName": "AsyncStorageExample"
78
}
89
],
910
"resources": {
10-
"android": ["index.android.jsbundle"],
11-
"ios": ["index.ios.jsbundle"],
12-
"macos": ["index.macos.jsbundle"]
11+
"android": [
12+
"index.android.jsbundle"
13+
],
14+
"ios": [
15+
"index.ios.jsbundle"
16+
],
17+
"macos": [
18+
"index.macos.jsbundle"
19+
],
20+
"windows": [
21+
"main.windows.bundle"
22+
]
1323
}
1424
}
Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,12 @@
1-
module.exports = {
2-
presets: ["module:@react-native/babel-preset"],
3-
};
1+
const path = require('path');
2+
const { getConfig } = require('react-native-builder-bob/babel-config');
3+
const pkg = require('../package.json');
4+
5+
const root = path.resolve(__dirname, '..');
6+
7+
module.exports = getConfig(
8+
{
9+
presets: ['module:@react-native/babel-preset'],
10+
},
11+
{ root, pkg }
12+
);

packages/default-storage/example/ios/AsyncStorageExample.xcworkspace/contents.xcworkspacedata

Lines changed: 3 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/default-storage/example/macos/AsyncStorageExample.xcworkspace/contents.xcworkspacedata

Lines changed: 3 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
const path = require('path');
2+
const { getDefaultConfig } = require('@react-native/metro-config');
3+
const { getConfig } = require('react-native-builder-bob/metro-config');
4+
const pkg = require('../package.json');
5+
6+
const root = path.resolve(__dirname, '..');
7+
8+
/**
9+
* Metro configuration
10+
* https://facebook.github.io/metro/docs/configuration
11+
*
12+
* @type {import('metro-config').MetroConfig}
13+
*/
14+
module.exports = getConfig(getDefaultConfig(__dirname), {
15+
root,
16+
pkg,
17+
project: __dirname,
18+
});
Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
{
2+
"name": "example-defaultstorage",
3+
"version": "0.0.1",
4+
"private": true,
5+
"scripts": {
6+
"start": "react-native start",
7+
"start:android": "react-native run-android",
8+
"start:ios": "react-native run-ios",
9+
"start:macos": "react-native run-macos --project-path macos --scheme AsyncStorageExample",
10+
"start:web": "expo start --web",
11+
"start:windows": "install-windows-test-app -p windows && react-native run-windows --logging --no-packager --no-telemetry",
12+
"start:windows:fabric": "install-windows-test-app -p windows --use-fabric && react-native run-windows --logging --no-packager --no-telemetry",
13+
"build:e2e:android": "scripts/android_e2e.sh 'build'",
14+
"build:e2e:ios": "scripts/ios_e2e.sh 'build'",
15+
"build:e2e:macos": "scripts/macos_e2e.sh 'build'",
16+
"bundle:android": "scripts/android_e2e.sh 'bundle'",
17+
"bundle:ios": "scripts/ios_e2e.sh 'bundle'",
18+
"bundle:macos": "react-native bundle --entry-file index.js --platform macos --dev false --bundle-output index.macos.jsbundle",
19+
"test:e2e:android": "scripts/android_e2e.sh 'test'",
20+
"test:e2e:ios": "scripts/ios_e2e.sh 'test'",
21+
"test:e2e:macos": "scripts/macos_e2e.sh 'test'"
22+
},
23+
"installConfig": {
24+
"hoistingLimits": "workspaces"
25+
},
26+
"dependencies": {
27+
"react": "18.3.1",
28+
"react-native": "0.76.1"
29+
},
30+
"devDependencies": {
31+
"@babel/core": "^7.25.2",
32+
"@babel/preset-env": "^7.25.3",
33+
"@babel/runtime": "^7.25.0",
34+
"@react-native-community/cli": "15.0.0",
35+
"@react-native-community/cli-platform-android": "15.0.0",
36+
"@react-native-community/cli-platform-ios": "15.0.0",
37+
"@react-native/babel-preset": "0.76.1",
38+
"@react-native/metro-config": "0.76.1",
39+
"@react-native/typescript-config": "0.76.1",
40+
"@rnx-kit/metro-config": "^2.0.0",
41+
"react-native-builder-bob": "^0.33.3",
42+
"react-native-test-app": "^4.0.3"
43+
}
44+
}
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
const path = require("path");
2+
const pkg = require("../package.json");
3+
const { configureProjects } = require("react-native-test-app");
4+
5+
module.exports = {
6+
project: configureProjects({
7+
android: {
8+
sourceDir: "android",
9+
},
10+
ios: {
11+
sourceDir: "ios",
12+
automaticPodsInstallation: true,
13+
},
14+
macos: {
15+
sourceDir: "macos",
16+
},
17+
windows: {
18+
sourceDir: "windows",
19+
solutionFile: path.join("windows", "AsyncStorageExample.sln"),
20+
},
21+
}),
22+
dependencies: {
23+
[pkg.name]: {
24+
root: path.join(__dirname, ".."),
25+
},
26+
},
27+
};

packages/default-storage/scripts/android_e2e.sh renamed to packages/default-storage/example/scripts/android_e2e.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,20 +3,20 @@
33
build_apk() {
44
echo
55
echo "[Android E2E] Building APK"
6-
(cd example/android; ./gradlew assembleRelease -PAsyncStorage_useNextStorage=false --max-workers 2)
6+
(cd android; ./gradlew assembleRelease -PAsyncStorage_useNextStorage=false --max-workers 2)
77
}
88

99
bundle_js() {
1010
extraArgs="$@"
1111
echo
1212
echo "[Android E2E] Bundling JS"
13-
react-native bundle --entry-file index.ts --platform android --bundle-output example/index.android.jsbundle --dev false $extraArgs
13+
react-native bundle --entry-file index.ts --platform android --bundle-output index.android.jsbundle --dev false $extraArgs
1414
}
1515

1616

1717
run_e2e_test() {
1818
echo "[Android E2E] Running tests"
19-
wdio run example/__tests__/android.conf.ts
19+
wdio run __tests__/android.conf.ts
2020
}
2121

2222
case $1 in

0 commit comments

Comments
 (0)