expo-bbase 1.3.5 → 1.4.0
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/README.md +3 -0
- package/dist/index.js +32 -42
- package/dist/index.js.map +1 -1
- package/package.json +3 -2
- package/templates/assets/adaptive-icon.png +0 -0
- package/templates/assets/favicon.png +0 -0
- package/templates/assets/fonts/Nunito-Bold.ttf +0 -0
- package/templates/assets/icon.png +0 -0
- package/templates/assets/splash-icon.png +0 -0
package/README.md
CHANGED
|
@@ -231,6 +231,9 @@ MIT
|
|
|
231
231
|
|
|
232
232
|
## 更新日志
|
|
233
233
|
|
|
234
|
+
### v1.3.5
|
|
235
|
+
- 🔧 **修复 Facebook 登录模块**:移除已废弃的 `expo-facebook`(SDK 54 不再包含),改用 `expo-auth-session` + `expo-web-browser` 实现 Facebook OAuth 登录
|
|
236
|
+
|
|
234
237
|
### v1.3.4
|
|
235
238
|
- 🔧 **目录结构修复**:去除 `src/` 层,模块文件(`modules/`、`api/`、`stores/` 等)与 `app/` 平级
|
|
236
239
|
- 📝 修正 Facebook 登录模块描述(SDK 54 不再支持 `expo-facebook`,改用 `expo-auth-session`)
|
package/dist/index.js
CHANGED
|
@@ -1719,29 +1719,12 @@ var i18n_default = i18nModule;
|
|
|
1719
1719
|
var animationModule = {
|
|
1720
1720
|
id: "animation",
|
|
1721
1721
|
name: "\u52A8\u753B/\u624B\u52BF",
|
|
1722
|
-
description: "Reanimated 4 + Gesture Handler + Worklets",
|
|
1722
|
+
description: "Reanimated 4 + Gesture Handler + Worklets\uFF08\u5DF2\u9ED8\u8BA4\u5305\u542B\uFF0C\u6B64\u6A21\u5757\u4EC5\u6DFB\u52A0\u5C01\u88C5\u4EE3\u7801\uFF09",
|
|
1723
1723
|
defaultChecked: false,
|
|
1724
|
-
|
|
1725
|
-
|
|
1726
|
-
"react-native-gesture-handler": "~2.28.0",
|
|
1727
|
-
"react-native-worklets": "~0.5.1"
|
|
1728
|
-
},
|
|
1724
|
+
// Dependencies are already included in base package.json
|
|
1725
|
+
dependencies: {},
|
|
1729
1726
|
devDependencies: {},
|
|
1730
1727
|
files: [
|
|
1731
|
-
{
|
|
1732
|
-
path: "babel.config.js",
|
|
1733
|
-
content: `module.exports = function (api) {
|
|
1734
|
-
api.cache(true);
|
|
1735
|
-
return {
|
|
1736
|
-
presets: [
|
|
1737
|
-
["babel-preset-expo", { jsxImportSource: "nativewind" }],
|
|
1738
|
-
"nativewind/babel",
|
|
1739
|
-
],
|
|
1740
|
-
plugins: [],
|
|
1741
|
-
};
|
|
1742
|
-
};
|
|
1743
|
-
`
|
|
1744
|
-
},
|
|
1745
1728
|
{
|
|
1746
1729
|
path: "modules/animation/index.ts",
|
|
1747
1730
|
content: lines(
|
|
@@ -1798,9 +1781,6 @@ var animationModule = {
|
|
|
1798
1781
|
)
|
|
1799
1782
|
}
|
|
1800
1783
|
],
|
|
1801
|
-
// When animation module is selected, babel.config.js is overwritten above
|
|
1802
|
-
// to re-enable babel-preset-expo's auto-detection of reanimated/worklets plugins
|
|
1803
|
-
// (since those packages will be installed as dependencies)
|
|
1804
1784
|
babelPlugins: []
|
|
1805
1785
|
};
|
|
1806
1786
|
var animation_default = animationModule;
|
|
@@ -3179,7 +3159,7 @@ SplashScreen.preventAutoHideAsync();
|
|
|
3179
3159
|
export default function RootLayout() {
|
|
3180
3160
|
const colorScheme = useColorScheme();
|
|
3181
3161
|
const [loaded] = useFonts({
|
|
3182
|
-
|
|
3162
|
+
NunitoBold: require("../assets/fonts/Nunito-Bold.ttf"),
|
|
3183
3163
|
});
|
|
3184
3164
|
|
|
3185
3165
|
useEffect(() => {
|
|
@@ -3527,7 +3507,9 @@ export {};
|
|
|
3527
3507
|
"version": "1.0.0",
|
|
3528
3508
|
"orientation": "portrait",
|
|
3529
3509
|
"userInterfaceStyle": "light",
|
|
3510
|
+
"icon": "./assets/icon.png",
|
|
3530
3511
|
"splash": {
|
|
3512
|
+
"image": "./assets/splash-icon.png",
|
|
3531
3513
|
"resizeMode": "contain",
|
|
3532
3514
|
"backgroundColor": "#ffffff"
|
|
3533
3515
|
},
|
|
@@ -3536,11 +3518,19 @@ export {};
|
|
|
3536
3518
|
"bundleIdentifier": "com.${projectName}.app"
|
|
3537
3519
|
},
|
|
3538
3520
|
"android": {
|
|
3521
|
+
"adaptiveIcon": {
|
|
3522
|
+
"foregroundImage": "./assets/adaptive-icon.png",
|
|
3523
|
+
"backgroundColor": "#ffffff"
|
|
3524
|
+
},
|
|
3539
3525
|
"package": "com.${projectName}.app"
|
|
3540
3526
|
},
|
|
3527
|
+
"web": {
|
|
3528
|
+
"favicon": "./assets/favicon.png"
|
|
3529
|
+
},
|
|
3541
3530
|
"plugins": [
|
|
3542
3531
|
"expo-router",
|
|
3543
|
-
"expo-splash-screen"
|
|
3532
|
+
"expo-splash-screen",
|
|
3533
|
+
"react-native-reanimated"
|
|
3544
3534
|
]
|
|
3545
3535
|
}
|
|
3546
3536
|
}
|
|
@@ -3550,25 +3540,14 @@ export {};
|
|
|
3550
3540
|
{
|
|
3551
3541
|
path: "tsconfig.json",
|
|
3552
3542
|
content: `{
|
|
3543
|
+
"extends": "expo/tsconfig.base",
|
|
3553
3544
|
"compilerOptions": {
|
|
3554
|
-
"target": "ESNext",
|
|
3555
|
-
"module": "ESNext",
|
|
3556
|
-
"moduleResolution": "bundler",
|
|
3557
|
-
"lib": ["ESNext"],
|
|
3558
3545
|
"strict": true,
|
|
3559
|
-
"jsx": "react-jsx",
|
|
3560
|
-
"esModuleInterop": true,
|
|
3561
|
-
"skipLibCheck": true,
|
|
3562
|
-
"forceConsistentCasingInFileNames": true,
|
|
3563
|
-
"resolveJsonModule": true,
|
|
3564
|
-
"isolatedModules": true,
|
|
3565
|
-
"noEmit": true,
|
|
3566
3546
|
"paths": {
|
|
3567
3547
|
"@/*": ["./*"]
|
|
3568
3548
|
}
|
|
3569
3549
|
},
|
|
3570
|
-
"include": ["**/*.ts", "**/*.tsx", ".expo/types/**/*.ts", "expo-env.d.ts"]
|
|
3571
|
-
"exclude": ["node_modules"]
|
|
3550
|
+
"include": ["**/*.ts", "**/*.tsx", ".expo/types/**/*.ts", "expo-env.d.ts", "nativewind-env.d.ts"]
|
|
3572
3551
|
}
|
|
3573
3552
|
`
|
|
3574
3553
|
},
|
|
@@ -3579,7 +3558,8 @@ export {};
|
|
|
3579
3558
|
module.exports = {
|
|
3580
3559
|
content: [
|
|
3581
3560
|
"./app/**/*.{js,jsx,ts,tsx}",
|
|
3582
|
-
"./
|
|
3561
|
+
"./components/**/*.{js,jsx,ts,tsx}",
|
|
3562
|
+
"./modules/**/*.{js,jsx,ts,tsx}",
|
|
3583
3563
|
],
|
|
3584
3564
|
presets: [require("nativewind/preset")],
|
|
3585
3565
|
theme: {
|
|
@@ -3643,7 +3623,7 @@ module.exports = withNativeWind(config, { input: "./global.css" });
|
|
|
3643
3623
|
api.cache(true);
|
|
3644
3624
|
return {
|
|
3645
3625
|
presets: [
|
|
3646
|
-
["babel-preset-expo", { jsxImportSource: "nativewind"
|
|
3626
|
+
["babel-preset-expo", { jsxImportSource: "nativewind" }],
|
|
3647
3627
|
"nativewind/babel",
|
|
3648
3628
|
],
|
|
3649
3629
|
plugins: [],
|
|
@@ -3772,7 +3752,7 @@ function generateLoginTabsTemplates(projectName) {
|
|
|
3772
3752
|
"export default function RootLayout() {",
|
|
3773
3753
|
" const colorScheme = useColorScheme();",
|
|
3774
3754
|
" const [loaded] = useFonts({",
|
|
3775
|
-
'
|
|
3755
|
+
' NunitoBold: require("../assets/fonts/Nunito-Bold.ttf"),',
|
|
3776
3756
|
" });",
|
|
3777
3757
|
"",
|
|
3778
3758
|
" useEffect(() => {",
|
|
@@ -4194,10 +4174,14 @@ function generateBasePackageJson(projectName) {
|
|
|
4194
4174
|
"expo-constants": "~18.0.13",
|
|
4195
4175
|
"expo-status-bar": "~3.0.9",
|
|
4196
4176
|
"expo-splash-screen": "~31.0.13",
|
|
4177
|
+
"expo-font": "~14.0.11",
|
|
4197
4178
|
react: "19.1.0",
|
|
4198
4179
|
"react-native": "0.81.5",
|
|
4199
4180
|
"react-native-safe-area-context": "~5.6.0",
|
|
4200
4181
|
"react-native-screens": "~4.16.0",
|
|
4182
|
+
"react-native-reanimated": "~4.1.1",
|
|
4183
|
+
"react-native-worklets": "~0.5.1",
|
|
4184
|
+
"react-native-gesture-handler": "~2.28.0",
|
|
4201
4185
|
nativewind: "^4.1.0",
|
|
4202
4186
|
tailwindcss: "^3.4.0",
|
|
4203
4187
|
"react-native-svg": "^15.8.0"
|
|
@@ -4211,7 +4195,7 @@ function generateBasePackageJson(projectName) {
|
|
|
4211
4195
|
|
|
4212
4196
|
// src/index.ts
|
|
4213
4197
|
var import_execa = require("execa");
|
|
4214
|
-
var CLI_VERSION = "1.
|
|
4198
|
+
var CLI_VERSION = "1.4.0";
|
|
4215
4199
|
var CONFIG_FILE = ".expo-bbase.json";
|
|
4216
4200
|
async function run() {
|
|
4217
4201
|
const program = new import_commander.Command();
|
|
@@ -4338,6 +4322,12 @@ async function createProject(projectName) {
|
|
|
4338
4322
|
await writeFile(filePath, content);
|
|
4339
4323
|
}
|
|
4340
4324
|
}
|
|
4325
|
+
spinner.text = "Copying assets...";
|
|
4326
|
+
const assetsSource = import_path2.default.join(__dirname, "..", "templates", "assets");
|
|
4327
|
+
const assetsTarget = import_path2.default.join(targetDir, "assets");
|
|
4328
|
+
if (import_fs_extra2.default.existsSync(assetsSource)) {
|
|
4329
|
+
import_fs_extra2.default.copySync(assetsSource, assetsTarget);
|
|
4330
|
+
}
|
|
4341
4331
|
spinner.text = "Generating package.json...";
|
|
4342
4332
|
const pkgJson = generateBasePackageJson(projectName);
|
|
4343
4333
|
const allDeps = {};
|