create-rsbuild 0.7.4 → 0.7.6
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/dist/index.js +10 -1
- package/package.json +1 -1
- package/template-eslint/common-js/eslint.config.mjs +8 -0
- package/template-eslint/common-js/extra-package.json +10 -0
- package/template-eslint/common-ts/eslint.config.mjs +10 -0
- package/template-eslint/common-ts/extra-package.json +11 -0
- package/template-eslint/react-js/eslint.config.mjs +11 -0
- package/template-eslint/react-js/extra-package.json +12 -0
- package/template-eslint/react-ts/eslint.config.mjs +13 -0
- package/template-eslint/react-ts/extra-package.json +13 -0
- package/template-eslint/svelte-js/eslint.config.mjs +20 -0
- package/template-eslint/svelte-js/extra-package.json +11 -0
- package/template-eslint/svelte-ts/eslint.config.mjs +28 -0
- package/template-eslint/svelte-ts/extra-package.json +13 -0
- package/template-eslint/vue-js/eslint.config.mjs +10 -0
- package/template-eslint/vue-js/extra-package.json +11 -0
- package/template-eslint/vue-ts/eslint.config.mjs +12 -0
- package/template-eslint/vue-ts/extra-package.json +12 -0
- package/template-prettier/.prettierignore +4 -0
- package/template-prettier/.prettierrc +1 -1
package/dist/index.js
CHANGED
|
@@ -1273,6 +1273,7 @@ async function main() {
|
|
|
1273
1273
|
message: "Select additional tools (use arrow keys / space bar)",
|
|
1274
1274
|
options: [
|
|
1275
1275
|
{ value: "biome", label: "Add Biome for code linting and formatting" },
|
|
1276
|
+
{ value: "eslint", label: "Add ESLint for code linting" },
|
|
1276
1277
|
{ value: "prettier", label: "Add Prettier for code formatting" }
|
|
1277
1278
|
]
|
|
1278
1279
|
})
|
|
@@ -1283,7 +1284,15 @@ async function main() {
|
|
|
1283
1284
|
copyFolder(srcFolder, distFolder, version, path2.basename(targetDir));
|
|
1284
1285
|
for (const tool of tools) {
|
|
1285
1286
|
const toolFolder = path2.join(packageRoot, `template-${tool}`);
|
|
1286
|
-
|
|
1287
|
+
if (tool === "eslint") {
|
|
1288
|
+
let subFolder = path2.join(toolFolder, `${framework}-${language}`);
|
|
1289
|
+
if (!fs.existsSync(subFolder)) {
|
|
1290
|
+
subFolder = path2.join(toolFolder, `common-${language}`);
|
|
1291
|
+
}
|
|
1292
|
+
copyFolder(subFolder, distFolder, version);
|
|
1293
|
+
} else {
|
|
1294
|
+
copyFolder(toolFolder, distFolder, version);
|
|
1295
|
+
}
|
|
1287
1296
|
}
|
|
1288
1297
|
const nextSteps = [
|
|
1289
1298
|
`cd ${targetDir}`,
|
package/package.json
CHANGED
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { fixupConfigRules } from '@eslint/compat';
|
|
2
|
+
import js from '@eslint/js';
|
|
3
|
+
import react from 'eslint-plugin-react/configs/recommended.js';
|
|
4
|
+
import globals from 'globals';
|
|
5
|
+
|
|
6
|
+
export default [
|
|
7
|
+
{ languageOptions: { globals: globals.browser } },
|
|
8
|
+
js.configs.recommended,
|
|
9
|
+
...fixupConfigRules(react),
|
|
10
|
+
{ ignores: ['dist/'] },
|
|
11
|
+
];
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { fixupConfigRules } from '@eslint/compat';
|
|
2
|
+
import js from '@eslint/js';
|
|
3
|
+
import react from 'eslint-plugin-react/configs/recommended.js';
|
|
4
|
+
import globals from 'globals';
|
|
5
|
+
import ts from 'typescript-eslint';
|
|
6
|
+
|
|
7
|
+
export default [
|
|
8
|
+
{ languageOptions: { globals: globals.browser } },
|
|
9
|
+
js.configs.recommended,
|
|
10
|
+
...ts.configs.recommended,
|
|
11
|
+
...fixupConfigRules(react),
|
|
12
|
+
{ ignores: ['dist/'] },
|
|
13
|
+
];
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import js from '@eslint/js';
|
|
2
|
+
import svelte from 'eslint-plugin-svelte';
|
|
3
|
+
import globals from 'globals';
|
|
4
|
+
|
|
5
|
+
/** @type {import('eslint').Linter.FlatConfig[]} */
|
|
6
|
+
export default [
|
|
7
|
+
js.configs.recommended,
|
|
8
|
+
...svelte.configs['flat/recommended'],
|
|
9
|
+
{
|
|
10
|
+
languageOptions: {
|
|
11
|
+
globals: {
|
|
12
|
+
...globals.browser,
|
|
13
|
+
...globals.node,
|
|
14
|
+
},
|
|
15
|
+
},
|
|
16
|
+
},
|
|
17
|
+
{
|
|
18
|
+
ignores: ['dist/'],
|
|
19
|
+
},
|
|
20
|
+
];
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import js from '@eslint/js';
|
|
2
|
+
import svelte from 'eslint-plugin-svelte';
|
|
3
|
+
import globals from 'globals';
|
|
4
|
+
import ts from 'typescript-eslint';
|
|
5
|
+
|
|
6
|
+
/** @type {import('eslint').Linter.FlatConfig[]} */
|
|
7
|
+
export default [
|
|
8
|
+
js.configs.recommended,
|
|
9
|
+
...ts.configs.recommended,
|
|
10
|
+
...svelte.configs['flat/recommended'],
|
|
11
|
+
{
|
|
12
|
+
languageOptions: {
|
|
13
|
+
globals: {
|
|
14
|
+
...globals.browser,
|
|
15
|
+
...globals.node,
|
|
16
|
+
},
|
|
17
|
+
},
|
|
18
|
+
},
|
|
19
|
+
{
|
|
20
|
+
files: ['**/*.svelte'],
|
|
21
|
+
languageOptions: {
|
|
22
|
+
parserOptions: {
|
|
23
|
+
parser: ts.parser,
|
|
24
|
+
},
|
|
25
|
+
},
|
|
26
|
+
},
|
|
27
|
+
{ ignores: ['dist/'] },
|
|
28
|
+
];
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import js from '@eslint/js';
|
|
2
|
+
import vue from 'eslint-plugin-vue';
|
|
3
|
+
import globals from 'globals';
|
|
4
|
+
|
|
5
|
+
export default [
|
|
6
|
+
{ languageOptions: { globals: globals.browser } },
|
|
7
|
+
js.configs.recommended,
|
|
8
|
+
...vue.configs['flat/essential'],
|
|
9
|
+
{ ignores: ['dist/'] },
|
|
10
|
+
];
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import js from '@eslint/js';
|
|
2
|
+
import vue from 'eslint-plugin-vue';
|
|
3
|
+
import globals from 'globals';
|
|
4
|
+
import ts from 'typescript-eslint';
|
|
5
|
+
|
|
6
|
+
export default [
|
|
7
|
+
{ languageOptions: { globals: globals.browser } },
|
|
8
|
+
js.configs.recommended,
|
|
9
|
+
...ts.configs.recommended,
|
|
10
|
+
...vue.configs['flat/essential'],
|
|
11
|
+
{ ignores: ['dist/'] },
|
|
12
|
+
];
|