vite-plus 0.1.17-alpha.1 → 0.1.17-alpha.3
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/create/bin.js
CHANGED
|
@@ -4,7 +4,7 @@ import { a as success, i as muted, r as log, t as accent } from "../terminal-P9a
|
|
|
4
4
|
import { A as selectPackageManager, B as log$1, D as promptGitHooks, E as downloadPackageManager$1, F as PackageManager, G as text, K as require_picocolors, L as cancel, M as displayRelative, N as templatesDir, O as runViteFmt, P as DependencyType, R as confirm, T as defaultInteractive, U as select, V as multiselect, W as spinner, a as writeAgentInstructions, b as rewriteMonorepoProject, k as runViteInstall, n as detectExistingAgentTargetPaths, p as installGitHooks, q, r as selectAgentTargetPaths, x as rewriteStandaloneProject, y as rewriteMonorepo, z as intro } from "../agent-BcSb6dt_.js";
|
|
5
5
|
import { t as lib_default } from "../lib-BamM40b7.js";
|
|
6
6
|
import { c as readJsonFile, o as editJsonFile, t as checkNpmPackageExists } from "../package-DhXOF9Xm.js";
|
|
7
|
-
import { a as detectExistingEditor, n as updatePackageJsonWithDeps, o as selectEditor, r as updateWorkspaceConfig, s as writeEditorConfigs, t as detectWorkspace$1 } from "../workspace-
|
|
7
|
+
import { a as detectExistingEditor, n as updatePackageJsonWithDeps, o as selectEditor, r as updateWorkspaceConfig, s as writeEditorConfigs, t as detectWorkspace$1 } from "../workspace-DEScrNRl.js";
|
|
8
8
|
import { t as renderCliDoc } from "../help-BtkjXtRM.js";
|
|
9
9
|
import path from "node:path";
|
|
10
10
|
import { runCommand, vitePlusHeader } from "../../binding/index.js";
|
|
@@ -4161,7 +4161,8 @@ Use \`vp create --list\` to list all available templates, or run \`vp create --h
|
|
|
4161
4161
|
projectRoot: fullPath,
|
|
4162
4162
|
editorId: selectedEditor,
|
|
4163
4163
|
interactive: options.interactive,
|
|
4164
|
-
silent: compactOutput
|
|
4164
|
+
silent: compactOutput,
|
|
4165
|
+
extraVsCodeSettings: { "npm.scriptRunner": "vp" }
|
|
4165
4166
|
});
|
|
4166
4167
|
resumeCreateProgress();
|
|
4167
4168
|
workspaceInfo.rootDir = fullPath;
|
|
@@ -4232,7 +4233,8 @@ Use \`vp create --list\` to list all available templates, or run \`vp create --h
|
|
|
4232
4233
|
projectRoot: fullPath,
|
|
4233
4234
|
editorId: selectedEditor,
|
|
4234
4235
|
interactive: options.interactive,
|
|
4235
|
-
silent: compactOutput
|
|
4236
|
+
silent: compactOutput,
|
|
4237
|
+
extraVsCodeSettings: { "npm.scriptRunner": "vp" }
|
|
4236
4238
|
});
|
|
4237
4239
|
resumeCreateProgress();
|
|
4238
4240
|
let installSummary;
|
package/dist/migration/bin.js
CHANGED
|
@@ -5,7 +5,7 @@ import { A as selectPackageManager, B as log$1, D as promptGitHooks, E as downlo
|
|
|
5
5
|
import { t as lib_default } from "../lib-BamM40b7.js";
|
|
6
6
|
import { a as readNearestPackageJson, i as hasVitePlusDependency } from "../package-DhXOF9Xm.js";
|
|
7
7
|
import { r as createMigrationReport } from "../report-DHdnkZbA.js";
|
|
8
|
-
import { i as detectEditorConflicts, o as selectEditor, s as writeEditorConfigs, t as detectWorkspace$1 } from "../workspace-
|
|
8
|
+
import { i as detectEditorConflicts, o as selectEditor, s as writeEditorConfigs, t as detectWorkspace$1 } from "../workspace-DEScrNRl.js";
|
|
9
9
|
import { t as renderCliDoc } from "../help-BtkjXtRM.js";
|
|
10
10
|
import path from "node:path";
|
|
11
11
|
import { vitePlusHeader } from "../../binding/index.js";
|
package/dist/versions.js
CHANGED
|
@@ -184,13 +184,17 @@ function detectEditorConflicts({ projectRoot, editorId }) {
|
|
|
184
184
|
}
|
|
185
185
|
return conflicts;
|
|
186
186
|
}
|
|
187
|
-
async function writeEditorConfigs({ projectRoot, editorId, interactive, conflictDecisions, silent = false }) {
|
|
187
|
+
async function writeEditorConfigs({ projectRoot, editorId, interactive, conflictDecisions, silent = false, extraVsCodeSettings }) {
|
|
188
188
|
if (!editorId) return;
|
|
189
189
|
const editorConfig = EDITORS.find((e) => e.id === editorId);
|
|
190
190
|
if (!editorConfig) return;
|
|
191
191
|
const targetDir = path.join(projectRoot, editorConfig.targetDir);
|
|
192
192
|
await fsPromises.mkdir(targetDir, { recursive: true });
|
|
193
|
-
for (const [fileName,
|
|
193
|
+
for (const [fileName, baseIncoming] of Object.entries(editorConfig.files)) {
|
|
194
|
+
const incoming = editorId === "vscode" && fileName === "settings.json" && extraVsCodeSettings ? {
|
|
195
|
+
...extraVsCodeSettings,
|
|
196
|
+
...baseIncoming
|
|
197
|
+
} : baseIncoming;
|
|
194
198
|
const filePath = path.join(targetDir, fileName);
|
|
195
199
|
if (fs.existsSync(filePath)) {
|
|
196
200
|
const displayPath = `${editorConfig.targetDir}/${fileName}`;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "vite-plus",
|
|
3
|
-
"version": "0.1.17-alpha.
|
|
3
|
+
"version": "0.1.17-alpha.3",
|
|
4
4
|
"description": "The Unified Toolchain for the Web",
|
|
5
5
|
"homepage": "https://viteplus.dev/guide",
|
|
6
6
|
"bugs": {
|
|
@@ -318,15 +318,15 @@
|
|
|
318
318
|
}
|
|
319
319
|
},
|
|
320
320
|
"dependencies": {
|
|
321
|
-
"@oxc-project/types": "=0.
|
|
321
|
+
"@oxc-project/types": "=0.124.0",
|
|
322
322
|
"oxfmt": "=0.44.0",
|
|
323
323
|
"oxlint": "=1.59.0",
|
|
324
324
|
"oxlint-tsgolint": "=0.20.0",
|
|
325
|
-
"@voidzero-dev/vite-plus-core": "0.1.17-alpha.
|
|
326
|
-
"@voidzero-dev/vite-plus-test": "0.1.17-alpha.
|
|
325
|
+
"@voidzero-dev/vite-plus-core": "0.1.17-alpha.3",
|
|
326
|
+
"@voidzero-dev/vite-plus-test": "0.1.17-alpha.3"
|
|
327
327
|
},
|
|
328
328
|
"devDependencies": {
|
|
329
|
-
"@napi-rs/cli": "^3.6.
|
|
329
|
+
"@napi-rs/cli": "^3.6.1",
|
|
330
330
|
"@nkzw/safe-word-list": "^3.1.0",
|
|
331
331
|
"@oxc-node/core": "^0.0.32",
|
|
332
332
|
"@types/cross-spawn": "^6.0.6",
|
|
@@ -348,8 +348,8 @@
|
|
|
348
348
|
"tsdown": "^0.21.7",
|
|
349
349
|
"validate-npm-package-name": "^7.0.2",
|
|
350
350
|
"yaml": "^2.8.1",
|
|
351
|
-
"
|
|
352
|
-
"
|
|
351
|
+
"@voidzero-dev/vite-plus-prompts": "0.0.0",
|
|
352
|
+
"vite": "npm:@voidzero-dev/vite-plus-core@0.1.17-alpha.3"
|
|
353
353
|
},
|
|
354
354
|
"napi": {
|
|
355
355
|
"binaryName": "vite-plus",
|
|
@@ -369,14 +369,14 @@
|
|
|
369
369
|
"node": "^20.19.0 || >=22.12.0"
|
|
370
370
|
},
|
|
371
371
|
"optionalDependencies": {
|
|
372
|
-
"@voidzero-dev/vite-plus-darwin-arm64": "0.1.17-alpha.
|
|
373
|
-
"@voidzero-dev/vite-plus-darwin-x64": "0.1.17-alpha.
|
|
374
|
-
"@voidzero-dev/vite-plus-linux-arm64-gnu": "0.1.17-alpha.
|
|
375
|
-
"@voidzero-dev/vite-plus-linux-arm64-musl": "0.1.17-alpha.
|
|
376
|
-
"@voidzero-dev/vite-plus-linux-x64-gnu": "0.1.17-alpha.
|
|
377
|
-
"@voidzero-dev/vite-plus-linux-x64-musl": "0.1.17-alpha.
|
|
378
|
-
"@voidzero-dev/vite-plus-win32-x64-msvc": "0.1.17-alpha.
|
|
379
|
-
"@voidzero-dev/vite-plus-win32-arm64-msvc": "0.1.17-alpha.
|
|
372
|
+
"@voidzero-dev/vite-plus-darwin-arm64": "0.1.17-alpha.3",
|
|
373
|
+
"@voidzero-dev/vite-plus-darwin-x64": "0.1.17-alpha.3",
|
|
374
|
+
"@voidzero-dev/vite-plus-linux-arm64-gnu": "0.1.17-alpha.3",
|
|
375
|
+
"@voidzero-dev/vite-plus-linux-arm64-musl": "0.1.17-alpha.3",
|
|
376
|
+
"@voidzero-dev/vite-plus-linux-x64-gnu": "0.1.17-alpha.3",
|
|
377
|
+
"@voidzero-dev/vite-plus-linux-x64-musl": "0.1.17-alpha.3",
|
|
378
|
+
"@voidzero-dev/vite-plus-win32-x64-msvc": "0.1.17-alpha.3",
|
|
379
|
+
"@voidzero-dev/vite-plus-win32-arm64-msvc": "0.1.17-alpha.3"
|
|
380
380
|
},
|
|
381
381
|
"scripts": {
|
|
382
382
|
"build": "oxnode -C dev ./build.ts",
|
|
@@ -9,7 +9,9 @@ For the best VS Code experience with Vite+, install the [Vite Plus Extension Pac
|
|
|
9
9
|
- `Oxc` for formatting and linting via `vp check`
|
|
10
10
|
- `Vitest` for test runs via `vp test`
|
|
11
11
|
|
|
12
|
-
When you create or migrate a project, Vite+ prompts whether you want editor config written for VS Code.
|
|
12
|
+
When you create or migrate a project, Vite+ prompts whether you want editor config written for VS Code. `vp create` additionally sets `npm.scriptRunner` to `vp` so the VS Code NPM Scripts panel runs scripts through the Vite+ task runner. For migrated or existing projects, you can add this setting manually (see below).
|
|
13
|
+
|
|
14
|
+
You can also manually set up the VS Code config:
|
|
13
15
|
|
|
14
16
|
`.vscode/extensions.json`
|
|
15
17
|
|
|
@@ -34,3 +36,13 @@ When you create or migrate a project, Vite+ prompts whether you want editor conf
|
|
|
34
36
|
```
|
|
35
37
|
|
|
36
38
|
This gives the project a shared default formatter and enables Oxc-powered fix actions on save. Setting `oxc.fmt.configPath` to `./vite.config.ts` keeps editor format-on-save aligned with the `fmt` block in your Vite+ config. Vite+ uses `formatOnSaveMode: "file"` because Oxfmt does not support partial formatting.
|
|
39
|
+
|
|
40
|
+
To let the VS Code NPM Scripts panel run scripts through `vp`, add the following to your `.vscode/settings.json`:
|
|
41
|
+
|
|
42
|
+
```json
|
|
43
|
+
{
|
|
44
|
+
"npm.scriptRunner": "vp"
|
|
45
|
+
}
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
This is included automatically by `vp create` but not by `vp migrate`, since existing projects may have team members who do not have `vp` installed locally.
|