@modern-js/utils 2.15.0 → 2.15.1-alpha.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.
@@ -49,7 +49,7 @@ const getRouteId = (componentPath, routesDir, entryName) => {
49
49
  } else {
50
50
  id = `${entryName}_${pathWithoutExt}`;
51
51
  }
52
- return id;
52
+ return id.replace(/\[(.*?)\]/g, "($1)");
53
53
  };
54
54
  // Annotate the CommonJS export names for ESM import in node:
55
55
  0 && (module.exports = {
@@ -16,7 +16,7 @@ const getRouteId = (componentPath, routesDir, entryName) => {
16
16
  } else {
17
17
  id = `${entryName}_${pathWithoutExt}`;
18
18
  }
19
- return id;
19
+ return id.replace(/\[(.*?)\]/g, "($1)");
20
20
  };
21
21
  export {
22
22
  getPathWithoutExt,
package/package.json CHANGED
@@ -11,7 +11,7 @@
11
11
  "modern",
12
12
  "modern.js"
13
13
  ],
14
- "version": "2.15.0",
14
+ "version": "2.15.1-alpha.0",
15
15
  "jsnext:source": "./src/index.ts",
16
16
  "types": "./dist/types/index.d.ts",
17
17
  "main": "./dist/index.js",