@lcap/nasl-unified-frontend-generator 4.0.0-rc.2 → 4.0.0-rc.4

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.mjs CHANGED
@@ -1266,8 +1266,8 @@ var reactComponentLibHackPlugin = makePlugin({
1266
1266
  }
1267
1267
 
1268
1268
  Object.assign(utils, {
1269
- jsonSerialize: JSON.stringify,
1270
- jsonDeserialize: JSON.parse,
1269
+ jsonSerialize: utils.JsonSerialize || JSON.stringify,
1270
+ jsonDeserialize: utils.JsonDeserialize || JSON.parse,
1271
1271
  });
1272
1272
 
1273
1273
  const logging = {
@@ -7362,14 +7362,10 @@ var VueRouterPlugin = class {
7362
7362
  r.meta
7363
7363
  )}, children: [${childrenStr}], ${componentCode} }`;
7364
7364
  } else if (r.kind === "redirect") {
7365
- const replaceWildCardForVue3 = (frameworkKind, path2) => {
7366
- if (frameworkKind === "vue3" && path2 === "*") {
7367
- return "/:pathMatch(.*)*";
7368
- }
7369
- return path2;
7370
- };
7371
- const processedPath = replaceWildCardForVue3(config.frameworkKind, path);
7372
- return `{path: "${processedPath}", redirect: ${JSON.stringify(r.redirect)}}`;
7365
+ if (["vue3"].includes(config.frameworkKind) && path === "*") {
7366
+ return `{ path: "/:pathMatch(.*)*", redirect: ${JSON.stringify(r.redirect)} }`;
7367
+ }
7368
+ return `{ path: "${path}", redirect: to => to.path.replace(/\\/$/, '') + '/' + ${JSON.stringify(r.redirect)} }`;
7373
7369
  }
7374
7370
  notImplemented(r);
7375
7371
  }