@superblocksteam/cli 2.0.6-next.46 → 2.0.6-next.47

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/README.md CHANGED
@@ -14,7 +14,7 @@ $ npm install -g @superblocksteam/cli
14
14
  $ superblocks COMMAND
15
15
  running command...
16
16
  $ superblocks (--version)
17
- @superblocksteam/cli/2.0.6-next.46 linux-x64 node-v20.19.0
17
+ @superblocksteam/cli/2.0.6-next.47 linux-x64 node-v20.19.0
18
18
  $ superblocks --help [COMMAND]
19
19
  USAGE
20
20
  $ superblocks COMMAND
package/dist/index.js CHANGED
@@ -413120,7 +413120,7 @@ init_cjs_shims();
413120
413120
  var templates = {
413121
413121
  "api-builder-to-yaml": {
413122
413122
  "bootstrap.mjs": 'import { register } from "node:module";\nimport { pathToFileURL } from "node:url";\n\nregister("./shim-loader.mjs", pathToFileURL("./"));\n',
413123
- "package.json": '{\n "type": "module",\n "dependencies": {\n "acorn": "^8.14.0",\n "prettier": "^3.5.3",\n "yaml": "^2.7.1"\n },\n "devDependencies": {\n "@types/node": "^22.15.18",\n "@typescript-eslint/parser": "^8.17.0",\n "eslint": "^9.26.0",\n "typescript": "^5.8.3",\n "vitest": "^3.2.0"\n }\n}\n',
413123
+ "package.json": '{\n "type": "module",\n "dependencies": {\n "acorn": "^8.14.0",\n "prettier": "^3.5.3",\n "yaml": "^2.7.1"\n },\n "devDependencies": {\n "@types/node": "^22.15.18",\n "@typescript-eslint/parser": "^8.34.0",\n "eslint": "^9.26.0",\n "typescript": "^5.8.3",\n "vitest": "^3.2.0"\n }\n}\n',
413124
413124
  "shim-loader.mjs": 'import path from "path";\nimport { pathToFileURL } from "url";\n\nconst overrideMap = {\n "@superblocksteam/library": "./dist/superblocks-library-shim/index.js",\n};\n\nexport async function resolve(specifier, context, nextResolve) {\n if (overrideMap[specifier]) {\n const fullPath = path.resolve(overrideMap[specifier]);\n return {\n shortCircuit: true,\n url: pathToFileURL(fullPath).href,\n };\n }\n\n return nextResolve(specifier, context);\n}\n',
413125
413125
  "src/do-eval-to-sdk.ts": 'import fs from "fs";\nimport path from "path";\nimport { fileURLToPath } from "url";\n\n// finds all JavaScript files in the `dist/apis-to-transform` directory,\n// imports each module, converts its JSON representation to SDK,\n// and outputs a JSON map with filenames as keys and SDK content as values.\n\nasync function main() {\n const __filename = fileURLToPath(import.meta.url);\n const __dirname = path.dirname(__filename);\n\n const apisDir = path.resolve(__dirname, "./to-sdk");\n\n const files = fs.readdirSync(apisDir);\n\n const jsFiles = files.filter(\n (file) => file.endsWith(".js") && file !== "__template__.js",\n );\n\n const results: Record<string, string> = {};\n\n for (const jsFile of jsFiles) {\n const filePath = path.join(apisDir, jsFile);\n const absolutePath = path.resolve(filePath);\n\n try {\n const fileUrl = new URL(`file://${absolutePath}`);\n const module = await import(fileUrl.href);\n\n const defaultExport = module.default;\n\n if (defaultExport && typeof defaultExport.toSDK === "function") {\n const sdkData = await defaultExport.toSDK();\n\n results[jsFile] = sdkData;\n } else {\n console.warn(`${jsFile}: Default export doesn\'t have a toSDK method`);\n }\n } catch (error) {\n console.error(`Error processing ${jsFile}:`, error);\n }\n }\n\n console.log(JSON.stringify(results, null, 2));\n}\n\nmain().catch((error) => {\n console.error("Error:", error);\n process.exit(1);\n});\n',
413126
413126
  "src/do-eval-to-yaml.ts": 'import fs from "fs";\nimport path from "path";\nimport { fileURLToPath } from "url";\nimport yaml from "yaml";\n\n// finds all JavaScript files in the `dist/apis-to-transform` directory,\n// imports each module, converts its JSON representation to YAML,\n// and outputs a JSON map with filenames as keys and YAML content as values.\n\nasync function main() {\n const __filename = fileURLToPath(import.meta.url);\n const __dirname = path.dirname(__filename);\n\n const apisDir = path.resolve(__dirname, "./to-yaml");\n\n const files = fs.readdirSync(apisDir);\n\n const jsFiles = files.filter((file) => file.endsWith(".js"));\n\n const results: Record<string, string> = {};\n\n for (const jsFile of jsFiles) {\n const filePath = path.join(apisDir, jsFile);\n const absolutePath = path.resolve(filePath);\n\n try {\n const fileUrl = new URL(`file://${absolutePath}`);\n const module = await import(fileUrl.href);\n\n const defaultExport = module.default;\n\n if (defaultExport && typeof defaultExport.toJSON === "function") {\n const jsonData = await defaultExport.toJSON();\n\n const yamlContent = yaml.stringify(jsonData);\n\n results[jsFile] = yamlContent;\n } else {\n console.warn(`${jsFile}: Default export doesn\'t have a toJSON method`);\n }\n } catch (error) {\n console.error(`Error processing ${jsFile}:`, error);\n }\n }\n\n console.log(JSON.stringify(results, null, 2));\n}\n\nmain().catch((error) => {\n console.error("Error:", error);\n process.exit(1);\n});\n',
@@ -442878,7 +442878,7 @@ var import_util30 = __toESM(require_dist3(), 1);
442878
442878
  // ../sdk/package.json
442879
442879
  var package_default = {
442880
442880
  name: "@superblocksteam/sdk",
442881
- version: "2.0.6-next.46",
442881
+ version: "2.0.6-next.47",
442882
442882
  type: "module",
442883
442883
  description: "Superblocks JS SDK",
442884
442884
  homepage: "https://www.superblocks.com",
@@ -442919,11 +442919,11 @@ var package_default = {
442919
442919
  "@opentelemetry/semantic-conventions": "^1.28.0",
442920
442920
  "@rollup/wasm-node": "^4.35.0",
442921
442921
  "@superblocksteam/bucketeer-sdk": "0.5.0",
442922
- "@superblocksteam/library": "2.0.6-next.46",
442923
- "@superblocksteam/library-shared": "2.0.6-next.46",
442922
+ "@superblocksteam/library": "2.0.6-next.47",
442923
+ "@superblocksteam/library-shared": "2.0.6-next.47",
442924
442924
  "@superblocksteam/shared": "0.9198.0",
442925
- "@superblocksteam/util": "2.0.6-next.46",
442926
- "@superblocksteam/vite-plugin-file-sync": "2.0.6-next.46",
442925
+ "@superblocksteam/util": "2.0.6-next.47",
442926
+ "@superblocksteam/vite-plugin-file-sync": "2.0.6-next.47",
442927
442927
  "@vitejs/plugin-react": "^4.3.4",
442928
442928
  axios: "^1.4.0",
442929
442929
  chokidar: "^4.0.3",
@@ -450532,7 +450532,7 @@ async function startVite({ app, httpServer: httpServer2, root: root2, mode, port
450532
450532
  const isCustomBuildEnabled2 = await isCustomComponentsEnabled();
450533
450533
  const customFolder = path37.join(root2, "custom");
450534
450534
  const draftsFolder = path37.join(root2, ".superblocks");
450535
- const cdnUrl = "https://assets-cdn.superblocks.com/library/2.0.6-next.46";
450535
+ const cdnUrl = "https://assets-cdn.superblocks.com/library/2.0.6-next.47";
450536
450536
  const env3 = loadEnv(mode, root2, "");
450537
450537
  const hmrPort = await getFreePort();
450538
450538
  const hmrOptions = {
@@ -577,5 +577,5 @@
577
577
  "strict": true
578
578
  }
579
579
  },
580
- "version": "2.0.6-next.46"
580
+ "version": "2.0.6-next.47"
581
581
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@superblocksteam/cli",
3
- "version": "2.0.6-next.46",
3
+ "version": "2.0.6-next.47",
4
4
  "type": "module",
5
5
  "description": "Official Superblocks CLI",
6
6
  "homepage": "https://www.superblocks.com",
@@ -42,9 +42,9 @@
42
42
  "devDependencies": {
43
43
  "@eslint/js": "^9.16.0",
44
44
  "@oclif/test": "^4.1.11",
45
- "@superblocksteam/sdk": "2.0.6-next.46",
45
+ "@superblocksteam/sdk": "2.0.6-next.47",
46
46
  "@superblocksteam/shared": "0.9198.0",
47
- "@superblocksteam/util": "2.0.6-next.46",
47
+ "@superblocksteam/util": "2.0.6-next.47",
48
48
  "@types/babel__core": "^7.20.0",
49
49
  "@types/chai": "^4",
50
50
  "@types/fs-extra": "^11.0.1",