vectorvesper 1.1.0 → 1.2.0
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 +13 -2
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -909,6 +909,7 @@ async function stripTypes(content, filename) {
|
|
|
909
909
|
return result.code;
|
|
910
910
|
}
|
|
911
911
|
async function fileToJs(target, content) {
|
|
912
|
+
if (/\.d\.ts$/i.test(target)) return { target, content };
|
|
912
913
|
if (!isTsSource(target)) return { target, content };
|
|
913
914
|
try {
|
|
914
915
|
const code = await stripTypes(content, target);
|
|
@@ -1057,6 +1058,11 @@ async function addCommand(slug, options = {}) {
|
|
|
1057
1058
|
const t = await maybeTranspile(resolvedComponents, false);
|
|
1058
1059
|
resolvedComponents = t.components;
|
|
1059
1060
|
transpileWarnings = t.warnings;
|
|
1061
|
+
} else {
|
|
1062
|
+
resolvedComponents = resolvedComponents.map((c) => ({
|
|
1063
|
+
...c,
|
|
1064
|
+
files: c.files.filter((f) => f.type !== "types")
|
|
1065
|
+
}));
|
|
1060
1066
|
}
|
|
1061
1067
|
spinner.text = "Checking file conflicts...";
|
|
1062
1068
|
let planned;
|
|
@@ -1245,6 +1251,11 @@ async function updateCommand(slug, options = {}) {
|
|
|
1245
1251
|
const t = await maybeTranspile(components, false);
|
|
1246
1252
|
components = t.components;
|
|
1247
1253
|
transpileWarnings.push(...t.warnings);
|
|
1254
|
+
} else {
|
|
1255
|
+
components = components.map((c) => ({
|
|
1256
|
+
...c,
|
|
1257
|
+
files: c.files.filter((f) => f.type !== "types")
|
|
1258
|
+
}));
|
|
1248
1259
|
}
|
|
1249
1260
|
const planned = planFiles(components, installDir, projectRoot);
|
|
1250
1261
|
writeFiles(planned.map((f) => ({ absolutePath: f.absolutePath, content: f.content })));
|
|
@@ -1386,7 +1397,7 @@ Remove ${slug}
|
|
|
1386
1397
|
import fs9 from "fs";
|
|
1387
1398
|
import path9 from "path";
|
|
1388
1399
|
import pc9 from "picocolors";
|
|
1389
|
-
var CLI_VERSION = true ? "1.
|
|
1400
|
+
var CLI_VERSION = true ? "1.2.0" : "0.0.0-dev";
|
|
1390
1401
|
async function infoCommand() {
|
|
1391
1402
|
console.log(pc9.bold(pc9.cyan("\nVector Vesper Diagnostics\n")));
|
|
1392
1403
|
const projectInfo = detectProject();
|
|
@@ -1684,7 +1695,7 @@ async function whoamiCommand() {
|
|
|
1684
1695
|
}
|
|
1685
1696
|
|
|
1686
1697
|
// src/index.ts
|
|
1687
|
-
var version = true ? "1.
|
|
1698
|
+
var version = true ? "1.2.0" : "0.0.0-dev";
|
|
1688
1699
|
var program = new Command();
|
|
1689
1700
|
program.name("vv").description("Vector Vesper CLI \u2014 add visual components to your React project").version(version).option("--verbose", "Show detailed debug output").hook("preAction", (thisCommand) => {
|
|
1690
1701
|
const opts = thisCommand.opts();
|