@valbuild/init 0.92.0 → 0.93.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.
|
@@ -312,7 +312,7 @@ function transformNextAppRouterValProvider(fileInfo, api, options) {
|
|
|
312
312
|
|
|
313
313
|
var packageJson = {
|
|
314
314
|
name: "@valbuild/init",
|
|
315
|
-
version: "0.
|
|
315
|
+
version: "0.93.0",
|
|
316
316
|
description: "Initialize a new val.build project",
|
|
317
317
|
repository: {
|
|
318
318
|
type: "git",
|
|
@@ -382,7 +382,7 @@ var VAL_SERVER = function VAL_SERVER(configImportPath, valModulesImportPath) {
|
|
|
382
382
|
// TODO: use from @valbuild/core
|
|
383
383
|
|
|
384
384
|
var VAL_CONFIG = function VAL_CONFIG(isTypeScript, options) {
|
|
385
|
-
return "import { initVal } from \"@valbuild/next\";\n\nconst { s, c, val, config, nextAppRouter } = initVal(".concat(JSON.stringify(options, null, 2), ");\n\n").concat(isTypeScript ? 'export type { t } from "@valbuild/next";' : "", ";\nexport { s, c, val, config, nextAppRouter };\n");
|
|
385
|
+
return "import { initVal } from \"@valbuild/next\";\n\nconst { s, c, val, config, nextAppRouter, externalPageRouter } = initVal(".concat(JSON.stringify(options, null, 2), ");\n\n").concat(isTypeScript ? 'export type { t } from "@valbuild/next";' : "", ";\nexport { s, c, val, config, nextAppRouter, externalPageRouter };\n");
|
|
386
386
|
};
|
|
387
387
|
var VAL_API_ROUTER = function VAL_API_ROUTER(valServerPath) {
|
|
388
388
|
return "import { valNextAppRouter } from \"".concat(valServerPath, "\";\n\nexport const GET = valNextAppRouter;\nexport const POST = valNextAppRouter;\nexport const PATCH = valNextAppRouter;\nexport const DELETE = valNextAppRouter;\nexport const PUT = valNextAppRouter;\nexport const HEAD = valNextAppRouter;\n");
|
|
@@ -312,7 +312,7 @@ function transformNextAppRouterValProvider(fileInfo, api, options) {
|
|
|
312
312
|
|
|
313
313
|
var packageJson = {
|
|
314
314
|
name: "@valbuild/init",
|
|
315
|
-
version: "0.
|
|
315
|
+
version: "0.93.0",
|
|
316
316
|
description: "Initialize a new val.build project",
|
|
317
317
|
repository: {
|
|
318
318
|
type: "git",
|
|
@@ -382,7 +382,7 @@ var VAL_SERVER = function VAL_SERVER(configImportPath, valModulesImportPath) {
|
|
|
382
382
|
// TODO: use from @valbuild/core
|
|
383
383
|
|
|
384
384
|
var VAL_CONFIG = function VAL_CONFIG(isTypeScript, options) {
|
|
385
|
-
return "import { initVal } from \"@valbuild/next\";\n\nconst { s, c, val, config, nextAppRouter } = initVal(".concat(JSON.stringify(options, null, 2), ");\n\n").concat(isTypeScript ? 'export type { t } from "@valbuild/next";' : "", ";\nexport { s, c, val, config, nextAppRouter };\n");
|
|
385
|
+
return "import { initVal } from \"@valbuild/next\";\n\nconst { s, c, val, config, nextAppRouter, externalPageRouter } = initVal(".concat(JSON.stringify(options, null, 2), ");\n\n").concat(isTypeScript ? 'export type { t } from "@valbuild/next";' : "", ";\nexport { s, c, val, config, nextAppRouter, externalPageRouter };\n");
|
|
386
386
|
};
|
|
387
387
|
var VAL_API_ROUTER = function VAL_API_ROUTER(valServerPath) {
|
|
388
388
|
return "import { valNextAppRouter } from \"".concat(valServerPath, "\";\n\nexport const GET = valNextAppRouter;\nexport const POST = valNextAppRouter;\nexport const PATCH = valNextAppRouter;\nexport const DELETE = valNextAppRouter;\nexport const PUT = valNextAppRouter;\nexport const HEAD = valNextAppRouter;\n");
|
|
@@ -300,7 +300,7 @@ function transformNextAppRouterValProvider(fileInfo, api, options) {
|
|
|
300
300
|
|
|
301
301
|
var packageJson = {
|
|
302
302
|
name: "@valbuild/init",
|
|
303
|
-
version: "0.
|
|
303
|
+
version: "0.93.0",
|
|
304
304
|
description: "Initialize a new val.build project",
|
|
305
305
|
repository: {
|
|
306
306
|
type: "git",
|
|
@@ -370,7 +370,7 @@ var VAL_SERVER = function VAL_SERVER(configImportPath, valModulesImportPath) {
|
|
|
370
370
|
// TODO: use from @valbuild/core
|
|
371
371
|
|
|
372
372
|
var VAL_CONFIG = function VAL_CONFIG(isTypeScript, options) {
|
|
373
|
-
return "import { initVal } from \"@valbuild/next\";\n\nconst { s, c, val, config, nextAppRouter } = initVal(".concat(JSON.stringify(options, null, 2), ");\n\n").concat(isTypeScript ? 'export type { t } from "@valbuild/next";' : "", ";\nexport { s, c, val, config, nextAppRouter };\n");
|
|
373
|
+
return "import { initVal } from \"@valbuild/next\";\n\nconst { s, c, val, config, nextAppRouter, externalPageRouter } = initVal(".concat(JSON.stringify(options, null, 2), ");\n\n").concat(isTypeScript ? 'export type { t } from "@valbuild/next";' : "", ";\nexport { s, c, val, config, nextAppRouter, externalPageRouter };\n");
|
|
374
374
|
};
|
|
375
375
|
var VAL_API_ROUTER = function VAL_API_ROUTER(valServerPath) {
|
|
376
376
|
return "import { valNextAppRouter } from \"".concat(valServerPath, "\";\n\nexport const GET = valNextAppRouter;\nexport const POST = valNextAppRouter;\nexport const PATCH = valNextAppRouter;\nexport const DELETE = valNextAppRouter;\nexport const PUT = valNextAppRouter;\nexport const HEAD = valNextAppRouter;\n");
|
package/package.json
CHANGED
package/src/templates.ts
CHANGED
|
@@ -74,10 +74,10 @@ export const VAL_CONFIG = (
|
|
|
74
74
|
options: ValConfig,
|
|
75
75
|
) => `import { initVal } from "@valbuild/next";
|
|
76
76
|
|
|
77
|
-
const { s, c, val, config, nextAppRouter } = initVal(${JSON.stringify(options, null, 2)});
|
|
77
|
+
const { s, c, val, config, nextAppRouter, externalPageRouter } = initVal(${JSON.stringify(options, null, 2)});
|
|
78
78
|
|
|
79
79
|
${isTypeScript ? 'export type { t } from "@valbuild/next";' : ""};
|
|
80
|
-
export { s, c, val, config, nextAppRouter };
|
|
80
|
+
export { s, c, val, config, nextAppRouter, externalPageRouter };
|
|
81
81
|
`;
|
|
82
82
|
|
|
83
83
|
export const VAL_API_ROUTER = (
|