@joystick.js/cli-canary 0.0.0-canary.89 → 0.0.0-canary.90

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.
@@ -1,7 +1,7 @@
1
1
  import fs from "fs";
2
2
  import generateId from "./generateId.js";
3
3
  var setComponentId_default = (file = "") => {
4
- const componentMapPath = process.env.NODE_ENV === "development" ? `./.joystick/build/componentMap.json` : `./.build/componentMap.json`;
4
+ const componentMapPath = ["development", "test"].includes(process.env.NODE_ENV) ? `./.joystick/build/componentMap.json` : `./.build/componentMap.json`;
5
5
  const componentMapExists = fs.existsSync(componentMapPath);
6
6
  const componentMap = componentMapExists ? JSON.parse(fs.readFileSync(componentMapPath, "utf-8")) : {};
7
7
  const parts = [...file?.matchAll(/\/\/ ui+.*/gi)]?.map((match) => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@joystick.js/cli-canary",
3
- "version": "0.0.0-canary.89",
3
+ "version": "0.0.0-canary.90",
4
4
  "type": "module",
5
5
  "description": "CLI for the Joystick JavaScript framework.",
6
6
  "main": "development.js",
@@ -3,7 +3,7 @@ import generateId from "./generateId.js";
3
3
 
4
4
  export default (file = "") => {
5
5
  const componentMapPath =
6
- process.env.NODE_ENV === "development"
6
+ ['development', 'test'].includes(process.env.NODE_ENV)
7
7
  ? `./.joystick/build/componentMap.json`
8
8
  : `./.build/componentMap.json`;
9
9
  const componentMapExists = fs.existsSync(componentMapPath);
@@ -524,7 +524,6 @@ const dev = async (options, { resolve, reject }) => {
524
524
  __dirname
525
525
  );
526
526
 
527
-
528
527
  if (options?.environment === 'test') {
529
528
  process.loader.text('Running tests...');
530
529
  // await runTests(options);