Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions bestax-migrate/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
"author": "Alex Smith",
"license": "MIT",
"engines": {
"node": ">=18.0.0"
"node": ">=22"
},
"repository": {
"type": "git",
Expand All @@ -51,7 +51,7 @@
},
"dependencies": {
"@babel/parser": "^7.26.0",
"chalk": "^5.6.2",
"chalk": "^6.0.0",
"commander": "^15.0.0",
"jscodeshift": "^17.3.0"
},
Expand All @@ -60,13 +60,13 @@
"@jest/globals": "^30.0.0",
"@types/jest": "^30.0.0",
"@types/jscodeshift": "^17.3.0",
"@types/node": "^26.1.1",
"@types/node": "^26.1.2",
"@types/react": "^19.0.0",
"@types/react-dom": "^19.0.0",
"jest": "^30.2.0",
"react": "^19.2.8",
"react-dom": "^19.2.8",
"ts-jest": "^29.4.6",
"ts-jest": "^29.4.12",
"typescript": "^6.0.3"
},
"publishConfig": {
Expand Down
13 changes: 10 additions & 3 deletions bestax-migrate/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,21 @@
* so tests can drive it without spawning a process.
*/

import { createCLI } from './cli.js';
// The version guard runs before anything is imported and uses no dependency of
// its own: import declarations are hoisted and evaluated before any statement
// here, and chalk >= 6 requires a Node this guard is meant to reject. A static
// import would fail to load first and replace the message below with an opaque
// loader error.
export {};

const [major] = process.versions.node.split('.').map(Number);
if (major < 18) {
if (major < 22) {
console.error(
`bestax-migrate requires Node 18 or newer (found ${process.versions.node}).`
`bestax-migrate requires Node 22 or newer (found ${process.versions.node}).`
);
process.exit(1);
}

const { createCLI } = await import('./cli.js');

createCLI().parse();
24 changes: 12 additions & 12 deletions bulma-ui/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -48,37 +48,37 @@
"@rollup/plugin-commonjs": "^29.0.3",
"@rollup/plugin-node-resolve": "^16.0.1",
"@rollup/plugin-typescript": "^12.1.0",
"@storybook/addon-docs": "^10.1.11",
"@storybook/addon-onboarding": "^10.1.11",
"@storybook/react-vite": "^10.1.11",
"@storybook/addon-docs": "^10.5.5",
"@storybook/addon-onboarding": "^10.5.5",
"@storybook/react-vite": "^10.5.5",
"@storybook/test-runner": "^0.24.4",
"@testing-library/jest-dom": "^6.5.0",
"@testing-library/jest-dom": "^7.0.0",
"@testing-library/react": "^16.3.1",
"@testing-library/user-event": "^14.5.2",
"@types/jest": "^30.0.0",
"@types/react": "^19.2.17",
"@types/react-dom": "^19.2.3",
"@typescript-eslint/eslint-plugin": "^8.65.0",
"@typescript-eslint/parser": "^8.65.0",
"eslint": "^10.5.0",
"eslint": "^10.8.0",
"eslint-config-prettier": "^10.1.5",
"eslint-plugin-prettier": "^5.2.1",
"eslint-plugin-react-hooks": "^7.1.1",
"eslint-plugin-storybook": "^10.1.11",
"eslint-plugin-storybook": "^10.5.5",
"ionicons": "^8.0.13",
"jest": "^30.2.0",
"jest-environment-jsdom": "^30.2.0",
"material-icons": "^1.13.14",
"material-symbols": "^0.45.2",
"playwright": "^1.61.1",
"material-symbols": "^0.45.9",
"playwright": "^1.62.0",
"prettier": "^3.9.6",
"rimraf": "^6.0.1",
"rollup": "^4.55.1",
"rollup": "^4.62.3",
"rollup-plugin-scss": "^4.0.1",
"rollup-plugin-visualizer": "^7.0.1",
"sass": "^1.97.2",
"storybook": "^10.1.11",
"ts-jest": "^29.4.6",
"sass": "^1.102.0",
"storybook": "^10.5.5",
"ts-jest": "^29.4.12",
"tslib": "^2.8.0",
"typescript": "^6.0.3",
"vite": "^8.1.5"
Expand Down
12 changes: 6 additions & 6 deletions create-bestax/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
"author": "Alex Smith",
"license": "MIT",
"engines": {
"node": ">=18.0.0"
"node": ">=22"
},
"repository": {
"type": "git",
Expand All @@ -53,22 +53,22 @@
"url": "https://github.com/allxsmith/bestax/issues"
},
"dependencies": {
"chalk": "^5.6.2",
"chalk": "^6.0.0",
"commander": "^15.0.0",
"figures": "^6.1.0",
"fs-extra": "^11.2.0",
"fs-extra": "^11.4.0",
"prompts": "^2.4.2"
},
"devDependencies": {
"@jest/globals": "^30.0.0",
"@playwright/test": "^1.57.0",
"@playwright/test": "^1.62.0",
"@types/fs-extra": "^11.0.4",
"@types/jest": "^30.0.0",
"@types/node": "^26.1.1",
"@types/node": "^26.1.2",
"@types/prompts": "^2.4.9",
"@types/wait-on": "^5.3.4",
"jest": "^30.2.0",
"ts-jest": "^29.4.6",
"ts-jest": "^29.4.12",
"typescript": "^6.0.3",
"wait-on": "^9.1.0"
},
Expand Down
26 changes: 16 additions & 10 deletions create-bestax/src/index.ts
Original file line number Diff line number Diff line change
@@ -1,23 +1,29 @@
#!/usr/bin/env node

import { createCLI } from './cli.js';
import chalk from 'chalk';

// Check Node.js version requirement (Breaking change for v2.0.0)
// The version guard deliberately runs before anything else is imported, and
// deliberately does not use chalk. `import` declarations are hoisted and
// evaluated before any statement in this module, and chalk >= 6 itself
// requires Node >= 22 — so a static import would fail to load on exactly the
// runtimes this guard exists to catch, replacing the message below with an
// opaque loader error. ./cli.js is pulled in dynamically for the same reason.
const currentNodeVersion = process.versions.node;
const majorVersion = parseInt(currentNodeVersion.split('.')[0], 10);
const MINIMUM_NODE_VERSION = 18;
const MINIMUM_NODE_VERSION = 22;

if (majorVersion < MINIMUM_NODE_VERSION) {
console.error(
chalk.red(
`Error: create-bestax requires Node.js v${MINIMUM_NODE_VERSION}.0.0 or higher.\n` +
`You are currently running Node.js v${currentNodeVersion}.\n` +
`Please upgrade your Node.js version.`
)
`Error: create-bestax requires Node.js v${MINIMUM_NODE_VERSION}.0.0 or higher.\n` +
`You are currently running Node.js v${currentNodeVersion}.\n` +
`Please upgrade your Node.js version.`
);
process.exit(1);
}

// Marks this file as a module. With every import now dynamic there is no
// static import left to do it, and top-level await requires a module.
export {};

const { createCLI } = await import('./cli.js');

const program = createCLI();
program.parse();
4 changes: 2 additions & 2 deletions docs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
"clsx": "^2.0.0",
"ionicons": "^8.0.13",
"material-icons": "^1.13.14",
"material-symbols": "^0.45.2",
"material-symbols": "^0.45.9",
"prism-react-renderer": "^2.3.0",
"react": "^19.2.8",
"react-dom": "^19.2.8",
Expand All @@ -37,7 +37,7 @@
"devDependencies": {
"@docusaurus/module-type-aliases": "^3.10.2",
"@docusaurus/types": "^3.10.2",
"docusaurus-plugin-llms": "^0.4.0",
"docusaurus-plugin-llms": "^0.5.1",
"raw-loader": "^4.0.2"
},
"browserslist": {
Expand Down
16 changes: 8 additions & 8 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,26 +31,26 @@
"devDependencies": {
"@commitlint/cli": "^21.2.1",
"@commitlint/config-conventional": "^21.2.0",
"@eslint-react/eslint-plugin": "^5.9.0",
"@eslint-react/eslint-plugin": "^5.18.0",
"@eslint/js": "^10.0.1",
"@semantic-release/changelog": "^6.0.3",
"@semantic-release/git": "^10.0.1",
"@semantic-release/changelog": "^7.0.0",
"@semantic-release/git": "^11.0.1",
"@semantic-release/github": "^12.0.9",
"@semantic-release/npm": "^13.1.3",
"bulma": "^1.0.4",
"eslint": "^10.5.0",
"eslint": "^10.8.0",
"eslint-config-prettier": "^10.1.5",
"eslint-plugin-prettier": "^5.2.1",
"globals": "^17.6.0",
"globals": "^17.8.0",
"husky": "^9.1.7",
"prettier": "^3.9.6",
"react": "^19.2.8",
"react-dom": "^19.2.8",
"semantic-release": "^25.0.8",
"ts-jest": "^29.4.6",
"turbo": "^2.7.3",
"ts-jest": "^29.4.12",
"turbo": "^2.10.7",
"typescript": "^6.0.3",
"wrangler": "^4.0.0"
"wrangler": "^4.114.0"
},
"keywords": [
"react",
Expand Down
Loading
Loading