@sleeperhq/mini-core 1.7.3 → 1.8.2

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/bin/build_mini.js CHANGED
@@ -69,7 +69,7 @@ const spawnProcess = (command, errorMessage) => {
69
69
  return new Promise((resolve) => {
70
70
  const child = isWindows
71
71
  ? spawn('cmd.exe', ['/c', command])
72
- : spawn(command, { shell: true });
72
+ : spawn(command, { env: process.env, shell: process.env.SHELL || true });
73
73
 
74
74
  child.stdout.on('data', (data) => {
75
75
  process.stdout.write(data); // output the data to the console
@@ -152,11 +152,14 @@ const main = async () => {
152
152
 
153
153
  const commands = getCommands(projectName);
154
154
 
155
- // Clean build folders
156
- await spawnProcess(commands.cleanAll, "clean command exited with non-zero code");
157
-
158
- // Run yarn + pod install
159
- await spawnProcess(commands.install, "clean command exited with non-zero code");
155
+ const shouldClean = await getInput("Clean and rebuild project? (y/n): ", 'y');
156
+ if (shouldClean === 'y') {
157
+ // Clean build folders
158
+ await spawnProcess(commands.cleanAll, "clean command exited with non-zero code");
159
+
160
+ // Run yarn + pod install
161
+ await spawnProcess(commands.install, "install command exited with non-zero code");
162
+ }
160
163
 
161
164
  // Build iOS
162
165
  printInfo("Building iOS...");
@@ -173,12 +176,12 @@ const main = async () => {
173
176
 
174
177
  // Create Zip Archive
175
178
  printInfo("Creating zip archive...");
176
- await spawnProcess(commands.cleanIndex, "clean command exited with non-zero code");
179
+ await spawnProcess(commands.cleanIndex, "clean index command exited with non-zero code");
177
180
  await spawnProcess(commands.zip, "zip command exited with non-zero code");
178
181
  printComplete(`Zip archive created successfully at ${commands.zipFilePath}`);
179
182
 
180
183
  // Clean build folders
181
- await spawnProcess(commands.cleanBuild, "clean command exited with non-zero code");
184
+ await spawnProcess(commands.cleanBuild, "clean build command exited with non-zero code");
182
185
 
183
186
  // Open output folder
184
187
  await spawnProcess(commands.openFile);
@@ -4,8 +4,6 @@ const os = require('os');
4
4
  const path = require('path');
5
5
  const fs = require('fs');
6
6
 
7
- const isWindows = os.platform() === 'win32';
8
-
9
7
  const printError = (error) => {
10
8
  console.error("\n\033[91m" + error + "\033[0m");
11
9
  };
@@ -37,7 +35,8 @@ const main = async () => {
37
35
  (packageName) => `import '${packageName}';`
38
36
  ).join('\n');
39
37
 
40
- let output = `/*
38
+ let output =
39
+ `/*
41
40
  This file is automatically generated when you
42
41
  add a package to your package.json and run yarn.
43
42
  Please do not edit manually.
@@ -47,6 +46,12 @@ ${packageList}
47
46
  `;
48
47
 
49
48
  fs.writeFileSync(packageListPath, output);
49
+
50
+ // Write a ./mini_packages.json file that shows all available packages in sleeper.
51
+ const source = 'node_modules/@sleeperhq/mini-core/mini_packages.json';
52
+ const destination = 'mini_packages.json';
53
+ fs.copyFile(source, destination, () => {});
54
+
50
55
  process.exit(0);
51
56
  };
52
57
 
@@ -0,0 +1,113 @@
1
+ {
2
+ "packages": {
3
+ "@babel/runtime": "7.15.4",
4
+ "@babel/plugin-transform-runtime": "7.15.0",
5
+ "@mattermost/react-native-paste-input": "0.6.4",
6
+ "@notifee/react-native": "7.8.0",
7
+ "@ptomasroos/react-native-multi-slider": "2.2.2",
8
+ "@react-native-camera-roll/camera-roll": "5.2.0",
9
+ "@react-native-community/blur": "3.6.0",
10
+ "@react-native-community/datetimepicker": "2.6.2",
11
+ "@react-native-community/hooks": "2.8.0",
12
+ "@react-native-community/netinfo": "9.3.7",
13
+ "@react-native-masked-view/masked-view": "0.2.8",
14
+ "@react-native-picker/picker": "1.16.8",
15
+ "@react-navigation/bottom-tabs": "6.5.4",
16
+ "@react-navigation/compat": "5.3.20",
17
+ "@react-navigation/native": "6.1.3",
18
+ "@react-navigation/stack": "6.3.12",
19
+ "@shopify/flash-list": "1.4.1",
20
+ "@sleeperhq/mini-core": "1.8.2",
21
+ "amazon-cognito-identity-js": "6.3.2",
22
+ "crypto-js": "3.3.0",
23
+ "decimal.js-light": "2.5.1",
24
+ "deep-diff": "1.0.2",
25
+ "he": "1.2.0",
26
+ "moment-timezone": "0.5.11",
27
+ "path": "0.12.7",
28
+ "react": "18.2.0",
29
+ "react-freeze": "1.0.3",
30
+ "react-native": "0.72.7",
31
+ "react-native-action-sheet": "2.2.0",
32
+ "react-native-animatable": "1.3.3",
33
+ "react-native-branch": "5.4.0",
34
+ "react-native-check-version": "1.0.20",
35
+ "react-native-color-matrix-image-filters": "5.2.10",
36
+ "react-native-compressor": "1.5.2",
37
+ "react-native-confirmation-code-field": "6.7.0",
38
+ "react-native-contacts": "5.2.8",
39
+ "react-native-create-thumbnail": "2.0.0-rc.2",
40
+ "react-native-date-picker": "4.2.2",
41
+ "react-native-detector": "0.2.1",
42
+ "react-native-device-info": "8.4.1",
43
+ "react-native-draggable-flatlist": "4.0.1",
44
+ "react-native-draggable-reanimated": "1.0.5",
45
+ "react-native-dropdownalert": "4.3.0",
46
+ "react-native-emoji-rain": "0.0.1",
47
+ "react-native-extra-dimensions-android": "1.2.5",
48
+ "react-native-fs": "2.18.0",
49
+ "react-native-gesture-handler": "2.14.0",
50
+ "react-native-google-places-autocomplete": "2.4.1",
51
+ "react-native-haptic-feedback": "1.6.0",
52
+ "react-native-image-crop-picker": "0.39.0",
53
+ "react-native-image-pan-zoom": "2.1.12",
54
+ "react-native-image-picker": "4.10.3",
55
+ "react-native-image-resizer": "1.4.5",
56
+ "react-native-iphone-x-helper": "1.3.1",
57
+ "react-native-json-tree": "1.3.0",
58
+ "react-native-keep-awake": "4.0.0",
59
+ "react-native-keyboard-aware-scroll-view": "0.9.5",
60
+ "react-native-keyboard-spacer": "0.4.1",
61
+ "react-native-linear-gradient": "2.8.3",
62
+ "react-native-modal": "13.0.0",
63
+ "react-native-modal-datetime-picker": "13.0.1",
64
+ "react-native-parsed-text": "0.0.21",
65
+ "react-native-permissions": "3.6.1",
66
+ "react-native-platform-touchable": "1.1.1",
67
+ "react-native-popup-dialog": "0.11.46",
68
+ "react-native-popup-menu": "0.16.1",
69
+ "react-native-progress": "4.1.2",
70
+ "react-native-qrcode-svg": "6.1.1",
71
+ "react-native-reanimated": "3.5.4",
72
+ "react-native-redash": "18.1.0",
73
+ "react-native-safe-area-context": "4.7.4",
74
+ "react-native-screens": "3.29.0",
75
+ "react-native-search-bar": "3.5.1",
76
+ "react-native-section-list-get-item-layout": "2.2.3",
77
+ "react-native-shake": "5.3.1",
78
+ "react-native-share": "7.3.9",
79
+ "react-native-shimmer-placeholder": "1.0.36",
80
+ "react-native-simple-toast": "1.1.3",
81
+ "react-native-sms": "1.11.0",
82
+ "react-native-snap-carousel": "3.9.1",
83
+ "react-native-sound": "0.11.1",
84
+ "react-native-sound-level": "1.1.5",
85
+ "react-native-spinkit": "1.5.1",
86
+ "react-native-svg": "13.14.0",
87
+ "react-native-swiper": "1.6.0-rc.3",
88
+ "react-native-tab-view": "3.5.0",
89
+ "react-native-tcp-socket": "6.0.6",
90
+ "react-native-triangle": "0.0.9",
91
+ "react-native-vector-icons": "10.0.0",
92
+ "react-native-video": "5.2.1",
93
+ "react-native-view-shot": "3.7.0",
94
+ "react-native-webview": "11.23.1",
95
+ "react-native-webp-format": "1.1.2",
96
+ "regenerator-runtime": "0.13.9",
97
+ "recyclerlistview": "4.2.0",
98
+ "rn-prompt": "1.0.4"
99
+ },
100
+ "overrides": {
101
+ "@callstack/repack": "2.7.0",
102
+ "@react-native-async-storage/async-storage": "1.15.15",
103
+ "@react-native-community/audio-toolkit": "2.0.3",
104
+ "react-native-chart-kit": "6.7.0",
105
+ "react-native-circular-progress": "1.3.6",
106
+ "react-native-fast-image": "8.5.11",
107
+ "react-native-interactable": "0.1.10",
108
+ "react-native-recyclerview-list": "0.3.4"
109
+ },
110
+ "requiredBy": {
111
+ "amazon-cognito-identity-js": "flexfantasy"
112
+ }
113
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sleeperhq/mini-core",
3
- "version": "1.7.3",
3
+ "version": "1.8.2",
4
4
  "description": "Core library frameworks for developing Sleeper Mini Apps.",
5
5
  "main": "index.ts",
6
6
  "types": "index.d.ts",
@@ -36,7 +36,7 @@
36
36
  "dependencies": {
37
37
  "@babel/runtime": "7.15.4",
38
38
  "@babel/plugin-transform-runtime": "7.15.0",
39
- "@callstack/repack": "blitzstudios/repack.git#callstack-repack-v2.7.0-gitpkg",
39
+ "@callstack/repack": "blitzstudios/repack.git#callstack-repack-v3.0.0-gitpkg",
40
40
  "@callstack/repack-dev-server": "blitzstudios/repack.git#callstack-repack-dev-server-v1.0.7-gitpkg",
41
41
  "@react-native-community/cli": "6.1.0",
42
42
  "@react-native-community/cli-types": "6.0.0",
@@ -44,7 +44,7 @@
44
44
  "axios": "0.15.3",
45
45
  "babel-loader": "9.1.2",
46
46
  "react-native-fast-image": "https://github.com/blitzstudios/react-native-fast-image.git#release/1.1",
47
- "react-native-interactable": "https://github.com/blitzstudios/react-native-interactable",
47
+ "react-native-interactable": "https://github.com/blitzstudios/react-native-interactable#release/1.1",
48
48
  "react-native-linear-gradient": "2.5.6",
49
49
  "react-native-rename": "^3.2.12",
50
50
  "react-refresh": "0.14.0",
@@ -54,15 +54,16 @@
54
54
  "webpack": "5.75.0"
55
55
  },
56
56
  "peerDependencies": {
57
- "react": "17.0.2",
58
- "react-native": "0.66.5",
57
+ "react": "18.2.0",
58
+ "react-native": "0.72.7",
59
59
  "react-native-svg": "13.7.0"
60
60
  },
61
61
  "devDependencies": {
62
62
  "@babel/core": "7.15.8",
63
63
  "@babel/preset-typescript": "7.21.4",
64
64
  "@react-native-community/eslint-config": "^2.0.0",
65
- "@types/react-native": "0.67.7",
65
+ "@types/react": "18.0.24",
66
+ "@types/react-native": "0.72.7",
66
67
  "@typescript-eslint/eslint-plugin": "^5.31.0",
67
68
  "@typescript-eslint/parser": "^5.31.0",
68
69
  "babel-jest": "^26.6.3",
@@ -74,8 +75,7 @@
74
75
  "typescript": "5.0.4"
75
76
  },
76
77
  "resolutions": {
77
- "react-devtools-core": "4.23.0",
78
- "@pmmmwh/react-refresh-webpack-plugin": "0.5.10"
78
+ "react-devtools-core": "4.23.0"
79
79
  },
80
80
  "jest": {
81
81
  "preset": "react-native"
package/webpack.config.js CHANGED
@@ -303,6 +303,12 @@ module.exports = env => {
303
303
  // split off into a seperate chunk, and named chunks will break (assume that's a bug that we can fix).
304
304
  },
305
305
  }),
306
+
307
+ // new Repack.plugins.ChunksToHermesBytecodePlugin({
308
+ // enabled: !dev,
309
+ // test: /\.(js)?bundle$/,
310
+ // exclude: /index\.bundle$/,
311
+ // }),
306
312
  ],
307
313
  };
308
314
  };