create-react-native-library 0.57.1 → 0.58.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/lib/constants.js +4 -3
- package/lib/constants.js.map +1 -1
- package/lib/exampleApp/generateExampleApp.js +18 -13
- package/lib/exampleApp/generateExampleApp.js.map +1 -1
- package/lib/inform.js +1 -1
- package/lib/inform.js.map +1 -1
- package/lib/prompt.js +21 -10
- package/lib/prompt.js.map +1 -1
- package/lib/template.js +34 -5
- package/lib/template.js.map +1 -1
- package/lib/utils/configureTools.js +73 -105
- package/lib/utils/configureTools.js.map +1 -1
- package/package.json +22 -22
- package/templates/common/$.github/workflows/ci.yml +8 -4
- package/templates/common/$package.json +4 -4
- package/templates/common/CONTRIBUTING.md +9 -5
- package/templates/common/README.md +1 -11
- package/templates/js-library/src/index.tsx +1 -3
- package/templates/js-library/src/multiply.tsx +3 -0
- package/templates/js-view/src/index.tsx +1 -0
- package/templates/js-view/src/{%- project.name %}View.tsx +9 -0
- package/templates/native-library-new/src/index.tsx +1 -5
- package/templates/native-library-new/src/multiply.native.tsx +5 -0
- package/templates/native-library-new/src/multiply.tsx +5 -0
- package/templates/native-view-new/src/index.tsx +1 -2
- package/templates/native-view-new/src/{%- project.name %}View.native.tsx +2 -0
- package/templates/native-view-new/src/{%- project.name %}View.tsx +11 -0
- package/templates/nitro-common/nitro.json +8 -2
- package/templates/nitro-module/src/index.tsx +1 -9
- package/templates/nitro-module/src/multiply.native.tsx +9 -0
- package/templates/nitro-module/src/multiply.tsx +5 -0
- package/templates/nitro-module/src/{%- project.name %}.nitro.ts +4 -2
- package/templates/nitro-view/src/index.tsx +1 -11
- package/templates/nitro-view/src/{%- project.name %}View.native.tsx +11 -0
- package/templates/nitro-view/src/{%- project.name %}View.tsx +11 -0
- package/templates/tools/eslint/~package.json +23 -0
- package/templates/tools/jest/src/__tests__/index.test.tsx +2 -0
- package/templates/tools/jest/~package.json +16 -0
- package/templates/tools/lefthook/~package.json +10 -0
- package/templates/tools/release-it/~package.json +28 -0
- package/templates/tools/turborepo/~package.json +5 -0
- package/templates/tools/vite/example/index.html +25 -0
- package/templates/tools/vite/example/index.js +11 -0
- package/templates/tools/vite/example/vite.config.mjs +15 -0
- package/templates/tools/vite/example/~package.json +14 -0
- package/templates/tools/vite/~package.json +9 -0
- /package/templates/{native-common-example → example-bare}/example/babel.config.js +0 -0
- /package/templates/{native-common-example → example-bare}/example/index.js +0 -0
- /package/templates/{native-common-example → example-native-common}/example/react-native.config.js +0 -0
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
{
|
|
2
|
+
"scripts": {
|
|
3
|
+
"lint": "eslint \"**/*.{js,ts,tsx}\""
|
|
4
|
+
},
|
|
5
|
+
"prettier": {
|
|
6
|
+
"quoteProps": "consistent",
|
|
7
|
+
"singleQuote": true,
|
|
8
|
+
"tabWidth": 2,
|
|
9
|
+
"trailingComma": "es5",
|
|
10
|
+
"useTabs": false
|
|
11
|
+
},
|
|
12
|
+
"devDependencies": {
|
|
13
|
+
"@eslint/compat": "^2.0.3",
|
|
14
|
+
"@eslint/eslintrc": "^3.3.5",
|
|
15
|
+
"@eslint/js": "^10.0.1",
|
|
16
|
+
"@react-native/eslint-config": "0.83.0",
|
|
17
|
+
"eslint": "^9.39.4",
|
|
18
|
+
"eslint-config-prettier": "^10.1.8",
|
|
19
|
+
"eslint-plugin-ft-flow": "^3.0.11",
|
|
20
|
+
"eslint-plugin-prettier": "^5.5.5",
|
|
21
|
+
"prettier": "^3.8.1"
|
|
22
|
+
}
|
|
23
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
{
|
|
2
|
+
"scripts": {
|
|
3
|
+
"test": "jest"
|
|
4
|
+
},
|
|
5
|
+
"jest": {
|
|
6
|
+
"preset": "react-native",
|
|
7
|
+
"modulePathIgnorePatterns": [
|
|
8
|
+
"<rootDir>/example/node_modules",
|
|
9
|
+
"<rootDir>/lib/"
|
|
10
|
+
]
|
|
11
|
+
},
|
|
12
|
+
"devDependencies": {
|
|
13
|
+
"@jest/globals": "^30.0.0",
|
|
14
|
+
"jest": "^30.3.0"
|
|
15
|
+
}
|
|
16
|
+
}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
{
|
|
2
|
+
"scripts": {
|
|
3
|
+
"release": "release-it --only-version"
|
|
4
|
+
},
|
|
5
|
+
"release-it": {
|
|
6
|
+
"git": {
|
|
7
|
+
"commitMessage": "chore: release ${version}",
|
|
8
|
+
"tagName": "v${version}"
|
|
9
|
+
},
|
|
10
|
+
"npm": {
|
|
11
|
+
"publish": true
|
|
12
|
+
},
|
|
13
|
+
"github": {
|
|
14
|
+
"release": true
|
|
15
|
+
},
|
|
16
|
+
"plugins": {
|
|
17
|
+
"@release-it/conventional-changelog": {
|
|
18
|
+
"preset": {
|
|
19
|
+
"name": "angular"
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
},
|
|
24
|
+
"devDependencies": {
|
|
25
|
+
"@release-it/conventional-changelog": "^10.0.6",
|
|
26
|
+
"release-it": "^19.2.4"
|
|
27
|
+
}
|
|
28
|
+
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
<!DOCTYPE html>
|
|
2
|
+
<html lang="en">
|
|
3
|
+
<head>
|
|
4
|
+
<meta charset="utf-8" />
|
|
5
|
+
<meta
|
|
6
|
+
name="viewport"
|
|
7
|
+
content="width=device-width, initial-scale=1, shrink-to-fit=no"
|
|
8
|
+
/>
|
|
9
|
+
<style>
|
|
10
|
+
html,
|
|
11
|
+
body {
|
|
12
|
+
height: 100%;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
#root {
|
|
16
|
+
display: flex;
|
|
17
|
+
height: 100%;
|
|
18
|
+
}
|
|
19
|
+
</style>
|
|
20
|
+
</head>
|
|
21
|
+
<body>
|
|
22
|
+
<div id="root"></div>
|
|
23
|
+
<script type="module" src="./index.js"></script>
|
|
24
|
+
</body>
|
|
25
|
+
</html>
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { AppRegistry } from 'react-native';
|
|
2
|
+
import App from './src/App';
|
|
3
|
+
import { name as appName } from './app.json';
|
|
4
|
+
|
|
5
|
+
AppRegistry.registerComponent(appName, () => App);
|
|
6
|
+
|
|
7
|
+
if (typeof document !== 'undefined') {
|
|
8
|
+
AppRegistry.runApplication(appName, {
|
|
9
|
+
rootTag: document.getElementById('root'),
|
|
10
|
+
});
|
|
11
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { fileURLToPath } from 'node:url';
|
|
2
|
+
|
|
3
|
+
import { defineConfig, mergeConfig } from 'vite';
|
|
4
|
+
|
|
5
|
+
import bobConfig from 'react-native-builder-bob/vite-config';
|
|
6
|
+
|
|
7
|
+
export default defineConfig((env) =>
|
|
8
|
+
mergeConfig(bobConfig(env), {
|
|
9
|
+
resolve: {
|
|
10
|
+
alias: {
|
|
11
|
+
'<%- project.slug -%>': fileURLToPath(new URL('..', import.meta.url)),
|
|
12
|
+
},
|
|
13
|
+
},
|
|
14
|
+
})
|
|
15
|
+
);
|
|
File without changes
|
|
File without changes
|
/package/templates/{native-common-example → example-native-common}/example/react-native.config.js
RENAMED
|
File without changes
|