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
7 changes: 5 additions & 2 deletions packages/create-rstack/template-app-react-js/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,11 @@
"type": "module",
"scripts": {
"build": "rs build",
"dev": "rs dev --open",
"preview": "rs preview"
"dev": "rs dev",

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Preserve browser opening in generated app dev scripts

When a user starts any newly generated application with the dev script, the page no longer opens automatically because this change removes --open from all four app templates. The CLI documentation explicitly identifies rs dev --open as the command that starts the server and opens the browser (website/docs/en/guide/cli/dev.mdx:17-22), so this is an unrelated user-visible regression from a tooling-only change; retain --open while adding the new scripts.

Useful? React with 👍 / 👎.

"format": "rs fmt",
"lint": "rs lint",
"preview": "rs preview",
"test": "rs test"
},
"dependencies": {
"react": "^19.2.8",
Expand Down
14 changes: 14 additions & 0 deletions packages/create-rstack/template-app-react-js/rstack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,17 @@ define.app(async () => {
plugins: [pluginReact()],
};
});

define.test({
// Configure Rstest
});

define.lint(async () => {
const { js, reactHooksPlugin, reactPlugin } = await import('rstack/lint');

return [
js.configs.recommended,
reactPlugin.configs.recommended,
reactHooksPlugin.configs.recommended,
];
});
7 changes: 5 additions & 2 deletions packages/create-rstack/template-app-react-ts/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,11 @@
"type": "module",
"scripts": {
"build": "rs build",
"dev": "rs dev --open",
"preview": "rs preview"
"dev": "rs dev",
"format": "rs fmt",
"lint": "rs lint",
"preview": "rs preview",
"test": "rs test"
},
"dependencies": {
"react": "^19.2.8",
Expand Down
15 changes: 15 additions & 0 deletions packages/create-rstack/template-app-react-ts/rstack.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,18 @@ define.app(async () => {
plugins: [pluginReact()],
};
});

define.test({
// Configure Rstest
});

define.lint(async () => {
const { js, ts, reactPlugin, reactHooksPlugin } = await import('rstack/lint');

return [
js.configs.recommended,
ts.configs.recommended,
reactPlugin.configs.recommended,
reactHooksPlugin.configs.recommended,
];
});
7 changes: 5 additions & 2 deletions packages/create-rstack/template-app-vanilla-js/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,11 @@
"type": "module",
"scripts": {
"build": "rs build",
"dev": "rs dev --open",
"preview": "rs preview"
"dev": "rs dev",
"format": "rs fmt",
"lint": "rs lint",
"preview": "rs preview",
"test": "rs test"
},
"devDependencies": {
"rstack": "^0.3.5"
Expand Down
14 changes: 13 additions & 1 deletion packages/create-rstack/template-app-vanilla-js/rstack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,16 @@
// Rstack configuration guide: https://rstack.rs/config
import { define } from 'rstack';

define.app({});
define.app({
// Configure Rsbuild
});

define.test({
// Configure Rstest
});

define.lint(async () => {
const { js } = await import('rstack/lint');

return [js.configs.recommended];
});
7 changes: 5 additions & 2 deletions packages/create-rstack/template-app-vanilla-ts/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,11 @@
"type": "module",
"scripts": {
"build": "rs build",
"dev": "rs dev --open",
"preview": "rs preview"
"dev": "rs dev",
"format": "rs fmt",
"lint": "rs lint",
"preview": "rs preview",
"test": "rs test"
},
"devDependencies": {
"@types/node": "^24.13.3",
Expand Down
14 changes: 13 additions & 1 deletion packages/create-rstack/template-app-vanilla-ts/rstack.config.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,16 @@
// Rstack configuration guide: https://rstack.rs/config
import { define } from 'rstack';

define.app({});
define.app({
// Configure Rsbuild
});

define.test({
// Configure Rstest
});

define.lint(async () => {
const { js, ts } = await import('rstack/lint');

return [js.configs.recommended, ts.configs.recommended];
});
2 changes: 2 additions & 0 deletions packages/create-rstack/template-lib-js/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@
"scripts": {
"build": "rs lib",
"dev": "rs lib --watch",
"format": "rs fmt",
"lint": "rs lint",
"test": "rs test",
"test:watch": "rs test --watch"
},
Expand Down
10 changes: 10 additions & 0 deletions packages/create-rstack/template-lib-js/rstack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,13 @@ import { define } from 'rstack';
define.lib({
syntax: ['node 22'],
});

define.test({
// Configure Rstest
});

define.lint(async () => {
const { js } = await import('rstack/lint');

return [js.configs.recommended];
});
2 changes: 2 additions & 0 deletions packages/create-rstack/template-lib-ts/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@
"scripts": {
"build": "rs lib",
"dev": "rs lib --watch",
"format": "rs fmt",
"lint": "rs lint",
"test": "rs test",
"test:watch": "rs test --watch"
},
Expand Down
10 changes: 10 additions & 0 deletions packages/create-rstack/template-lib-ts/rstack.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,13 @@ define.lib({
syntax: ['node 22'],
dts: true,
});

define.test({
// Configure Rstest
});

define.lint(async () => {
const { js, ts } = await import('rstack/lint');

return [js.configs.recommended, ts.configs.recommended];
});
1 change: 1 addition & 0 deletions packages/create-rstack/template-lib-ts/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
"skipLibCheck": true,
"types": ["rstack/types", "node"],
"useDefineForClassFields": true,
"rootDir": "src",

/* modules */
"moduleDetection": "force",
Expand Down