create-alistt69-kit 0.1.9 → 0.1.12

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.
Files changed (45) hide show
  1. package/LICENSE +20 -20
  2. package/README.md +123 -122
  3. package/bin/index.js +24 -24
  4. package/package.json +44 -44
  5. package/src/core/apply-features.js +14 -14
  6. package/src/core/collect-project-info.js +170 -194
  7. package/src/core/copy-base-template.js +11 -11
  8. package/src/core/create-project.js +99 -98
  9. package/src/core/install-dependencies.js +27 -27
  10. package/src/core/parse-cli-args.js +122 -122
  11. package/src/core/prepare-target-directory.js +69 -69
  12. package/src/core/render-project-readme.js +188 -75
  13. package/src/core/replace-tokens.js +45 -45
  14. package/src/core/restore-special-files.js +18 -18
  15. package/src/features/autoprefixer/files/postcss.config.cjs +4 -4
  16. package/src/features/autoprefixer/index.js +19 -23
  17. package/src/features/define-feature.js +33 -0
  18. package/src/features/eslint/files/eslint.config.mjs +133 -133
  19. package/src/features/eslint/index.js +30 -35
  20. package/src/features/index.js +25 -15
  21. package/src/features/react-router/files/src/app/App.tsx +20 -20
  22. package/src/features/react-router/files/src/app/layouts/app/index.tsx +36 -36
  23. package/src/features/react-router/files/src/app/providers/router/config/router.tsx +13 -13
  24. package/src/features/react-router/files/src/pages/error/index.ts +1 -1
  25. package/src/features/react-router/files/src/pages/error/lazy.ts +3 -3
  26. package/src/features/react-router/files/src/pages/error/page.tsx +7 -7
  27. package/src/features/react-router/files/src/pages/main/index.ts +1 -1
  28. package/src/features/react-router/files/src/pages/main/lazy.ts +3 -3
  29. package/src/features/react-router/files/src/pages/main/page.tsx +7 -7
  30. package/src/features/react-router/index.js +19 -23
  31. package/src/features/stylelint/files/stylelint.config.mjs +13 -13
  32. package/src/features/stylelint/index.js +24 -29
  33. package/src/templates/base/.editorconfig +11 -11
  34. package/src/templates/base/README.md +2 -2
  35. package/src/templates/base/babel.config.json +12 -12
  36. package/src/templates/base/gitignore +27 -27
  37. package/src/templates/base/package.json +48 -48
  38. package/src/templates/base/public/index.html +12 -12
  39. package/src/templates/base/src/app/App.tsx +17 -17
  40. package/src/templates/base/src/index.tsx +16 -16
  41. package/src/templates/base/src/styles/index.scss +13 -13
  42. package/src/templates/base/tsconfig.json +25 -25
  43. package/src/utils/console-format.js +11 -11
  44. package/src/utils/package-json.js +96 -72
  45. package/src/utils/package-manager.js +22 -22
package/LICENSE CHANGED
@@ -1,21 +1,21 @@
1
- MIT License
2
-
3
- Copyright (c) 2026 alistt69
4
-
5
- Permission is hereby granted, free of charge, to any person obtaining a copy
6
- of this software and associated documentation files (the “Software”), to deal
7
- in the Software without restriction, including without limitation the rights
8
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
- copies of the Software, and to permit persons to whom the Software is
10
- furnished to do so, subject to the following conditions:
11
-
12
- The above copyright notice and this permission notice shall be included in all
13
- copies or substantial portions of the Software.
14
-
15
- THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
1
+ MIT License
2
+
3
+ Copyright (c) 2026 alistt69
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the “Software”), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
21
  SOFTWARE.
package/README.md CHANGED
@@ -1,122 +1,123 @@
1
- <table width="100%">
2
- <tr>
3
- <td width="190" align="center">
4
- <img src="./assets/create-alistt69-kit-logo.svg" alt="Logo" width="170" height="170" style="margin-top: 50px;" />
5
- </td>
6
- <td>
7
- <h1>create-alistt69-kit</h1>
8
-
9
- > **One command. Zero config fatigue.**
10
- > Bootstrap a **React + TypeScript + Webpack** app with a solid starter setup and optional tooling you can enable when you need it.
11
-
12
- [![npm version](https://img.shields.io/npm/v/create-alistt69-kit.svg)](https://www.npmjs.com/package/create-alistt69-kit)
13
- [![Node.js Version](https://img.shields.io/badge/node-%3E%3D18.18-brightgreen)](https://nodejs.org/)
14
- [![License: MIT](https://img.shields.io/badge/license-MIT-blue.svg)](./LICENSE)
15
- </td>
16
- </tr>
17
- </table>
18
-
19
- ## ✨ Overview
20
-
21
- `create-alistt69-kit` is a project scaffolding tool for quickly creating a modern frontend app without burning time on repetitive setup.
22
-
23
- It generates a ready-to-run **React + TypeScript + Webpack** starter with a practical baseline and optional extras you can turn on when needed.
24
-
25
- ## 🔧 What’s inside
26
-
27
- | Tool | Purpose | Included |
28
- |------|----------------------------------|----------|
29
- | [React](https://react.dev/) | Web framework | Default |
30
- | [TypeScript](https://www.typescriptlang.org/) | Static typing | Default |
31
- | [Webpack](https://webpack.js.org/) | Bundling and build pipeline | Default |
32
- | [SCSS Modules](https://github.com/css-modules/css-modules) | Scoped styling | Default |
33
- | [SVGR](https://react-svgr.com/) | Import SVGs as React components | Default |
34
- | [Webpack Bundle Analyzer](https://github.com/webpack-contrib/webpack-bundle-analyzer) | Bundle size inspection | Default |
35
- | [ESLint](https://eslint.org/) + [eslint-stylistic](https://eslint.style/) | Code quality and stylistic rules | Optional |
36
- | [Stylelint](https://stylelint.io/) | Stylesheet linting | Optional |
37
- | [Autoprefixer](https://github.com/postcss/autoprefixer) | Automatic CSS vendor prefixes | Optional |
38
- | [React Router](https://reactrouter.com/) | Client-side routing | Optional |
39
-
40
- ---
41
-
42
- ## 🎯 Why use it?
43
-
44
- Setting up a frontend project from scratch usually means repeating the same stuff every time:
45
-
46
- - webpack config
47
- - TypeScript config
48
- - style handling
49
- - routing
50
- - linters
51
- - folder structure
52
-
53
- This starter removes that boilerplate so you can get straight to building.
54
-
55
- ---
56
-
57
- ## 📦 Requirements
58
-
59
- - **Node.js** `18.18` or higher
60
- - **npm**, **pnpm**, or **yarn**
61
-
62
- ---
63
-
64
- ## 🔥 Quick start
65
-
66
- Create a new app interactively:
67
-
68
- ```bash
69
- npm create alistt69-kit@latest
70
- ```
71
-
72
- Follow the prompts — or skip them entirely:
73
-
74
- ```bash
75
- npm create alistt69-kit@latest my-app -- -- --defaults
76
- ```
77
-
78
- ## 🛠️ Usage examples
79
-
80
- ```bash
81
- # Interactive setup
82
- npm create alistt69-kit@latest my-app
83
-
84
- # All defaults, no prompts
85
- npm create alistt69-kit@latest my-app -- -- --defaults
86
-
87
- # Skip dependency installation
88
- npm create alistt69-kit@latest my-app -- -- --no-install
89
-
90
- # Enable only selected features
91
- npm create alistt69-kit@latest my-app -- -- --features=eslint,react-router
92
-
93
- # Enable all optional features
94
- npm create alistt69-kit@latest my-app -- -- --features=all
95
-
96
- # Use pnpm as package manager
97
- npm create alistt69-kit@latest my-app -- -- --pm pnpm
98
-
99
- # Overwrite existing directory
100
- npm create alistt69-kit@latest my-app -- -- --defaults --overwrite
101
- ```
102
-
103
- ## ⚙️ CLI options
104
-
105
- | Option | Alias | Description |
106
- |--------|--------|-------------|
107
- | `--defaults` | `-def` | Skip prompts, use defaults |
108
- | `--overwrite` | | Overwrite target directory if it exists |
109
- | `--no-install` | — | Skip dependency installation |
110
- | `--features <list>` | — | Enable specific features (`eslint`, `react-router`, `all`) |
111
- | `--pm <name>` | — | Choose package manager (`npm`, `pnpm`, `yarn`) |
112
- | `--help` | `-h` | Show help |
113
-
114
- ## 🧪 Default behavior
115
-
116
- - All features are enabled by default
117
- - Package manager: `npm` (can be overridden with `--pm`)
118
- - Dependencies are installed automatically (skip with `--no-install`)
119
-
120
- ## 📄 License
121
-
122
- MIT — free and open for everyone.
1
+ <table width="100%">
2
+ <tr>
3
+ <td width="190" align="center">
4
+ <img src="./assets/create-alistt69-kit-logo.svg" alt="Logo" width="170" height="170" style="margin-top: 50px;" />
5
+ </td>
6
+ <td>
7
+ <h1>create-alistt69-kit</h1>
8
+
9
+ > **One command. Zero config fatigue.**
10
+ > Bootstrap a **React + TypeScript + Webpack** app with a solid starter setup and optional tooling you can enable when you need it.
11
+
12
+ [![npm version](https://img.shields.io/npm/v/create-alistt69-kit.svg)](https://www.npmjs.com/package/create-alistt69-kit)
13
+ [![Node.js Version](https://img.shields.io/badge/node-%3E%3D18.18-brightgreen)](https://nodejs.org/)
14
+ [![License: MIT](https://img.shields.io/badge/license-MIT-blue.svg)](./LICENSE)
15
+ [![CI](https://github.com/alistt69/create-alistt69-kit/actions/workflows/ci.yml/badge.svg)](https://github.com/alistt69/create-alistt69-kit/actions/workflows/ci.yml)
16
+ </td>
17
+ </tr>
18
+ </table>
19
+
20
+ ## ✨ Overview
21
+
22
+ `create-alistt69-kit` is a project scaffolding tool for quickly creating a modern frontend app without burning time on repetitive setup.
23
+
24
+ It generates a ready-to-run **React + TypeScript + Webpack** starter with a practical baseline and optional extras you can turn on when needed.
25
+
26
+ ## 🔧 What’s inside
27
+
28
+ | Tool | Purpose | Included |
29
+ |------|----------------------------------|----------|
30
+ | [React](https://react.dev/) | Web framework | Default |
31
+ | [TypeScript](https://www.typescriptlang.org/) | Static typing | Default |
32
+ | [Webpack](https://webpack.js.org/) | Bundling and build pipeline | Default |
33
+ | [SCSS Modules](https://github.com/css-modules/css-modules) | Scoped styling | Default |
34
+ | [SVGR](https://react-svgr.com/) | Import SVGs as React components | Default |
35
+ | [Webpack Bundle Analyzer](https://github.com/webpack-contrib/webpack-bundle-analyzer) | Bundle size inspection | Default |
36
+ | [ESLint](https://eslint.org/) + [eslint-stylistic](https://eslint.style/) | Code quality and stylistic rules | Optional |
37
+ | [Stylelint](https://stylelint.io/) | Stylesheet linting | Optional |
38
+ | [Autoprefixer](https://github.com/postcss/autoprefixer) | Automatic CSS vendor prefixes | Optional |
39
+ | [React Router](https://reactrouter.com/) | Client-side routing | Optional |
40
+
41
+ ---
42
+
43
+ ## 🎯 Why use it?
44
+
45
+ Setting up a frontend project from scratch usually means repeating the same stuff every time:
46
+
47
+ - webpack config
48
+ - TypeScript config
49
+ - style handling
50
+ - routing
51
+ - linters
52
+ - folder structure
53
+
54
+ This starter removes that boilerplate so you can get straight to building.
55
+
56
+ ---
57
+
58
+ ## 📦 Requirements
59
+
60
+ - **Node.js** `18.18` or higher
61
+ - **npm**, **pnpm**, or **yarn**
62
+
63
+ ---
64
+
65
+ ## 🔥 Quick start
66
+
67
+ Create a new app interactively:
68
+
69
+ ```bash
70
+ npm create alistt69-kit@latest
71
+ ```
72
+
73
+ Follow the prompts — or skip them entirely:
74
+
75
+ ```bash
76
+ npm create alistt69-kit@latest my-app -- -- --defaults
77
+ ```
78
+
79
+ ## 🛠️ Usage examples
80
+
81
+ ```bash
82
+ # Interactive setup
83
+ npm create alistt69-kit@latest my-app
84
+
85
+ # All defaults, no prompts
86
+ npm create alistt69-kit@latest my-app -- -- --defaults
87
+
88
+ # Skip dependency installation
89
+ npm create alistt69-kit@latest my-app -- -- --no-install
90
+
91
+ # Enable only selected features
92
+ npm create alistt69-kit@latest my-app -- -- --features=eslint,react-router
93
+
94
+ # Enable all optional features
95
+ npm create alistt69-kit@latest my-app -- -- --features=all
96
+
97
+ # Use pnpm as package manager
98
+ npm create alistt69-kit@latest my-app -- -- --pm pnpm
99
+
100
+ # Overwrite existing directory
101
+ npm create alistt69-kit@latest my-app -- -- --defaults --overwrite
102
+ ```
103
+
104
+ ## ⚙️ CLI options
105
+
106
+ | Option | Alias | Description |
107
+ |--------|--------|-------------|
108
+ | `--defaults` | `-def` | Skip prompts, use defaults |
109
+ | `--overwrite` | — | Overwrite target directory if it exists |
110
+ | `--no-install` | — | Skip dependency installation |
111
+ | `--features <list>` | — | Enable specific features (`eslint`, `react-router`, `all`) |
112
+ | `--pm <name>` | | Choose package manager (`npm`, `pnpm`, `yarn`) |
113
+ | `--help` | `-h` | Show help |
114
+
115
+ ## 🧪 Default behavior
116
+
117
+ - All features are enabled by default
118
+ - Package manager: `npm` (can be overridden with `--pm`)
119
+ - Dependencies are installed automatically (skip with `--no-install`)
120
+
121
+ ## 📄 License
122
+
123
+ MIT — free and open for everyone.
package/bin/index.js CHANGED
@@ -1,25 +1,25 @@
1
- #!/usr/bin/env node
2
-
3
- import { cancel } from '@clack/prompts';
4
- import process from 'node:process';
5
- import { createProject } from '../src/core/create-project.js';
6
- import { formatHelpMessage, parseCliArgs } from '../src/core/parse-cli-args.js';
7
-
8
- try {
9
- const cliArgs = parseCliArgs(process.argv.slice(2));
10
-
11
- if (cliArgs.showHelp) {
12
- console.log(formatHelpMessage());
13
- process.exit(0);
14
- }
15
-
16
- await createProject(cliArgs);
17
- } catch (error) {
18
- cancel(
19
- error instanceof Error
20
- ? `Failed to create project: ${error.message}`
21
- : 'Failed to create project',
22
- );
23
-
24
- process.exitCode = 1;
1
+ #!/usr/bin/env node
2
+
3
+ import { cancel } from '@clack/prompts';
4
+ import process from 'node:process';
5
+ import { createProject } from '../src/core/create-project.js';
6
+ import { formatHelpMessage, parseCliArgs } from '../src/core/parse-cli-args.js';
7
+
8
+ try {
9
+ const cliArgs = parseCliArgs(process.argv.slice(2));
10
+
11
+ if (cliArgs.showHelp) {
12
+ console.log(formatHelpMessage());
13
+ process.exit(0);
14
+ }
15
+
16
+ await createProject(cliArgs);
17
+ } catch (error) {
18
+ cancel(
19
+ error instanceof Error
20
+ ? `Failed to create project: ${error.message}`
21
+ : 'Failed to create project',
22
+ );
23
+
24
+ process.exitCode = 1;
25
25
  }
package/package.json CHANGED
@@ -1,44 +1,44 @@
1
- {
2
- "name": "create-alistt69-kit",
3
- "version": "0.1.9",
4
- "description": "Opinionated React + TypeScript + Webpack project generator by alistt69",
5
- "keywords": [
6
- "create",
7
- "cli",
8
- "scaffold",
9
- "generator",
10
- "react",
11
- "typescript",
12
- "webpack"
13
- ],
14
- "homepage": "https://github.com/alistt69/create-alistt69-kit#readme",
15
- "bugs": {
16
- "url": "https://github.com/alistt69/create-alistt69-kit/issues"
17
- },
18
- "repository": {
19
- "type": "git",
20
- "url": "git+https://github.com/alistt69/create-alistt69-kit.git"
21
- },
22
- "license": "MIT",
23
- "author": "alistt69",
24
- "type": "module",
25
- "bin": {
26
- "create-alistt69-kit": "bin/index.js"
27
- },
28
- "files": [
29
- "bin",
30
- "src",
31
- "README.md",
32
- "LICENSE"
33
- ],
34
- "scripts": {
35
- "dev": "node ./bin/index.js",
36
- "smoke": "node ./scripts/smoke.mjs"
37
- },
38
- "engines": {
39
- "node": ">=18.18.0"
40
- },
41
- "dependencies": {
42
- "@clack/prompts": "^0.10.1"
43
- }
44
- }
1
+ {
2
+ "name": "create-alistt69-kit",
3
+ "version": "0.1.12",
4
+ "description": "Opinionated React + TypeScript + Webpack project generator by alistt69",
5
+ "keywords": [
6
+ "create",
7
+ "cli",
8
+ "scaffold",
9
+ "generator",
10
+ "react",
11
+ "typescript",
12
+ "webpack"
13
+ ],
14
+ "homepage": "https://github.com/alistt69/create-alistt69-kit#readme",
15
+ "bugs": {
16
+ "url": "https://github.com/alistt69/create-alistt69-kit/issues"
17
+ },
18
+ "repository": {
19
+ "type": "git",
20
+ "url": "git+https://github.com/alistt69/create-alistt69-kit.git"
21
+ },
22
+ "license": "MIT",
23
+ "author": "alistt69",
24
+ "type": "module",
25
+ "bin": {
26
+ "create-alistt69-kit": "bin/index.js"
27
+ },
28
+ "files": [
29
+ "bin",
30
+ "src",
31
+ "README.md",
32
+ "LICENSE"
33
+ ],
34
+ "scripts": {
35
+ "dev": "node ./bin/index.js",
36
+ "smoke": "node ./scripts/smoke/index.mjs"
37
+ },
38
+ "engines": {
39
+ "node": ">=18.18.0"
40
+ },
41
+ "dependencies": {
42
+ "@clack/prompts": "^0.10.1"
43
+ }
44
+ }
@@ -1,15 +1,15 @@
1
- import { featuresById } from '../features/index.js';
2
-
3
- export async function applyFeatures({ projectPath, selectedFeatureIds }) {
4
- for (const featureId of selectedFeatureIds) {
5
- const feature = featuresById.get(featureId);
6
-
7
- if (!feature) {
8
- throw new Error(`Unknown feature: ${featureId}`);
9
- }
10
-
11
- await feature.apply({
12
- projectPath,
13
- });
14
- }
1
+ import { featuresById } from '../features/index.js';
2
+
3
+ export async function applyFeatures({ projectPath, selectedFeatureIds }) {
4
+ for (const featureId of selectedFeatureIds) {
5
+ const feature = featuresById.get(featureId);
6
+
7
+ if (!feature) {
8
+ throw new Error(`Unknown feature: ${featureId}`);
9
+ }
10
+
11
+ await feature.applyFeature({
12
+ projectPath,
13
+ });
14
+ }
15
15
  }