create-payload-app 4.0.0-internal.c7d5de4 → 4.0.0-internal.cb69780

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.
Files changed (123) hide show
  1. package/README.md +5 -0
  2. package/dist/commands.d.ts +4 -0
  3. package/dist/commands.d.ts.map +1 -0
  4. package/dist/commands.js +5 -0
  5. package/dist/commands.js.map +1 -0
  6. package/dist/lib/agent-config.d.ts +12 -0
  7. package/dist/lib/agent-config.d.ts.map +1 -0
  8. package/dist/lib/agent-config.js +15 -0
  9. package/dist/lib/agent-config.js.map +1 -0
  10. package/dist/lib/ast/package-json.d.ts +9 -0
  11. package/dist/lib/ast/package-json.d.ts.map +1 -1
  12. package/dist/lib/ast/package-json.js +34 -8
  13. package/dist/lib/ast/package-json.js.map +1 -1
  14. package/dist/lib/configure-payload-tsconfig.d.ts +5 -0
  15. package/dist/lib/configure-payload-tsconfig.d.ts.map +1 -0
  16. package/dist/lib/configure-payload-tsconfig.js +26 -0
  17. package/dist/lib/configure-payload-tsconfig.js.map +1 -0
  18. package/dist/lib/create-project.d.ts +1 -2
  19. package/dist/lib/create-project.d.ts.map +1 -1
  20. package/dist/lib/create-project.js +56 -29
  21. package/dist/lib/create-project.js.map +1 -1
  22. package/dist/lib/generate-secret.js +1 -1
  23. package/dist/lib/generate-secret.js.map +1 -1
  24. package/dist/lib/get-package-manager.d.ts +9 -0
  25. package/dist/lib/get-package-manager.d.ts.map +1 -1
  26. package/dist/lib/get-package-manager.js +20 -0
  27. package/dist/lib/get-package-manager.js.map +1 -1
  28. package/dist/lib/init-next.d.ts.map +1 -1
  29. package/dist/lib/init-next.js +5 -34
  30. package/dist/lib/init-next.js.map +1 -1
  31. package/dist/lib/init-tanstack.d.ts +18 -0
  32. package/dist/lib/init-tanstack.d.ts.map +1 -0
  33. package/dist/lib/init-tanstack.js +150 -0
  34. package/dist/lib/init-tanstack.js.map +1 -0
  35. package/dist/lib/tanstack/detect.d.ts +5 -0
  36. package/dist/lib/tanstack/detect.d.ts.map +1 -0
  37. package/dist/lib/tanstack/detect.js +131 -0
  38. package/dist/lib/tanstack/detect.js.map +1 -0
  39. package/dist/lib/tanstack/prepare.d.ts +23 -0
  40. package/dist/lib/tanstack/prepare.d.ts.map +1 -0
  41. package/dist/lib/tanstack/prepare.js +114 -0
  42. package/dist/lib/tanstack/prepare.js.map +1 -0
  43. package/dist/lib/tanstack/template-files.d.ts +50 -0
  44. package/dist/lib/tanstack/template-files.d.ts.map +1 -0
  45. package/dist/lib/tanstack/template-files.js +64 -0
  46. package/dist/lib/tanstack/template-files.js.map +1 -0
  47. package/dist/lib/tanstack/transform-root-route.d.ts +7 -0
  48. package/dist/lib/tanstack/transform-root-route.d.ts.map +1 -0
  49. package/dist/lib/tanstack/transform-root-route.js +747 -0
  50. package/dist/lib/tanstack/transform-root-route.js.map +1 -0
  51. package/dist/lib/tanstack/transform-router.d.ts +5 -0
  52. package/dist/lib/tanstack/transform-router.d.ts.map +1 -0
  53. package/dist/lib/tanstack/transform-router.js +301 -0
  54. package/dist/lib/tanstack/transform-router.js.map +1 -0
  55. package/dist/lib/tanstack/transform-vite-config.d.ts +14 -0
  56. package/dist/lib/tanstack/transform-vite-config.d.ts.map +1 -0
  57. package/dist/lib/tanstack/transform-vite-config.js +576 -0
  58. package/dist/lib/tanstack/transform-vite-config.js.map +1 -0
  59. package/dist/lib/templates.d.ts.map +1 -1
  60. package/dist/lib/templates.js +6 -0
  61. package/dist/lib/templates.js.map +1 -1
  62. package/dist/lib/update-payload-in-project.d.ts +18 -3
  63. package/dist/lib/update-payload-in-project.d.ts.map +1 -1
  64. package/dist/lib/update-payload-in-project.js +98 -18
  65. package/dist/lib/update-payload-in-project.js.map +1 -1
  66. package/dist/main.d.ts +20 -1
  67. package/dist/main.d.ts.map +1 -1
  68. package/dist/main.js +120 -30
  69. package/dist/main.js.map +1 -1
  70. package/dist/scripts/pack-template-files.js +18 -0
  71. package/dist/scripts/pack-template-files.js.map +1 -1
  72. package/dist/template/src/app/(frontend)/styles.css +8 -1
  73. package/dist/template/src/app/(payload)/admin/[[...segments]]/not-found.tsx +1 -2
  74. package/dist/template/src/app/(payload)/admin/[[...segments]]/page.tsx +1 -2
  75. package/dist/template/src/app/(payload)/api/[...slug]/route.ts +1 -2
  76. package/dist/template/src/app/(payload)/api/graphql/route.ts +1 -2
  77. package/dist/template/src/app/(payload)/api/graphql-playground/route.ts +1 -2
  78. package/dist/template/src/app/(payload)/layout.tsx +2 -3
  79. package/dist/template-tanstack/routes/_payload/admin.$.tsx +8 -0
  80. package/dist/template-tanstack/routes/_payload/admin.index.tsx +8 -0
  81. package/dist/template-tanstack/routes/_payload/api.$.ts +10 -0
  82. package/dist/template-tanstack/routes/_payload/importMap.js +32 -0
  83. package/dist/template-tanstack/routes/_payload/server.functions.ts +49 -0
  84. package/dist/template-tanstack/routes/_payload.tsx +30 -0
  85. package/dist/template-tanstack/src/collections/Folders.ts +16 -0
  86. package/dist/template-tanstack/src/collections/Media.ts +20 -0
  87. package/dist/template-tanstack/src/collections/Tags.ts +16 -0
  88. package/dist/template-tanstack/src/collections/Users.ts +14 -0
  89. package/dist/template-tanstack/src/payload.config.ts +40 -0
  90. package/dist/template-tanstack/src/payload.css +1 -0
  91. package/dist/types.d.ts +22 -3
  92. package/dist/types.d.ts.map +1 -1
  93. package/dist/types.js.map +1 -1
  94. package/dist/utils/messages.d.ts +1 -0
  95. package/dist/utils/messages.d.ts.map +1 -1
  96. package/dist/utils/messages.js +8 -6
  97. package/dist/utils/messages.js.map +1 -1
  98. package/package.json +5 -5
  99. package/dist/ast-integration.spec.js +0 -132
  100. package/dist/ast-integration.spec.js.map +0 -1
  101. package/dist/lib/ast/package-json.spec.js +0 -67
  102. package/dist/lib/ast/package-json.spec.js.map +0 -1
  103. package/dist/lib/ast/payload-config.spec.js +0 -365
  104. package/dist/lib/ast/payload-config.spec.js.map +0 -1
  105. package/dist/lib/ast/utils.spec.js +0 -226
  106. package/dist/lib/ast/utils.spec.js.map +0 -1
  107. package/dist/lib/create-project.spec.js +0 -190
  108. package/dist/lib/create-project.spec.js.map +0 -1
  109. package/dist/lib/download-skill.d.ts +0 -8
  110. package/dist/lib/download-skill.d.ts.map +0 -1
  111. package/dist/lib/download-skill.js +0 -35
  112. package/dist/lib/download-skill.js.map +0 -1
  113. package/dist/lib/manage-env-files.spec.js +0 -118
  114. package/dist/lib/manage-env-files.spec.js.map +0 -1
  115. package/dist/lib/select-agent.d.ts +0 -16
  116. package/dist/lib/select-agent.d.ts.map +0 -1
  117. package/dist/lib/select-agent.js +0 -67
  118. package/dist/lib/select-agent.js.map +0 -1
  119. package/dist/lib/wrap-next-config.spec.js +0 -167
  120. package/dist/lib/wrap-next-config.spec.js.map +0 -1
  121. package/dist/utils/resolvePackageVersion.spec.js +0 -77
  122. package/dist/utils/resolvePackageVersion.spec.js.map +0 -1
  123. /package/dist/template/src/app/(payload)/{custom.scss → custom.css} +0 -0
@@ -0,0 +1,114 @@
1
+ import fse from 'fs-extra';
2
+ import path from 'node:path';
3
+ import { TANSTACK_TEMPLATE_FILES } from './template-files.js';
4
+ import { transformTanStackRootRoute } from './transform-root-route.js';
5
+ import { transformTanStackRouter } from './transform-router.js';
6
+ import { transformTanStackViteConfig } from './transform-vite-config.js';
7
+ export async function prepareTanStackInit({ appDetails, templateRoot }) {
8
+ try {
9
+ const templateFilesResult = await getTemplateFiles({
10
+ appDetails,
11
+ templateRoot
12
+ });
13
+ if (!templateFilesResult.success) {
14
+ return templateFilesResult;
15
+ }
16
+ const [viteConfigContent, routerContent, rootRouteContent, ...templateContents] = await Promise.all([
17
+ fse.readFile(appDetails.viteConfigPath, 'utf8'),
18
+ fse.readFile(appDetails.routerPath, 'utf8'),
19
+ fse.readFile(appDetails.rootRoutePath, 'utf8'),
20
+ ...templateFilesResult.files.map(({ templatePath })=>fse.readFile(templatePath, 'utf8'))
21
+ ]);
22
+ const transformedFiles = [
23
+ {
24
+ filePath: appDetails.viteConfigPath,
25
+ result: transformTanStackViteConfig({
26
+ appDetails,
27
+ content: viteConfigContent
28
+ })
29
+ },
30
+ {
31
+ filePath: appDetails.routerPath,
32
+ result: transformTanStackRouter({
33
+ content: routerContent
34
+ })
35
+ },
36
+ {
37
+ filePath: appDetails.rootRoutePath,
38
+ result: transformTanStackRootRoute({
39
+ content: rootRouteContent,
40
+ kind: appDetails.kind
41
+ })
42
+ }
43
+ ];
44
+ const failedTransform = transformedFiles.find(({ result })=>!result.success);
45
+ if (failedTransform && !failedTransform.result.success) {
46
+ return {
47
+ reason: `Could not transform ${failedTransform.filePath}: ${failedTransform.result.reason}`,
48
+ success: false
49
+ };
50
+ }
51
+ const writes = transformedFiles.flatMap(({ filePath, result })=>result.success && result.modified ? [
52
+ {
53
+ content: result.content,
54
+ filePath
55
+ }
56
+ ] : []);
57
+ for (const [index, templateFile] of templateFilesResult.files.entries()){
58
+ const content = templateContents[index];
59
+ const { filePath } = templateFile;
60
+ if (await fse.pathExists(filePath)) {
61
+ const existingContent = await fse.readFile(filePath, 'utf8');
62
+ if (existingContent !== content) {
63
+ return {
64
+ reason: `A different file already exists at ${filePath}.`,
65
+ success: false
66
+ };
67
+ }
68
+ continue;
69
+ }
70
+ writes.push({
71
+ content,
72
+ filePath
73
+ });
74
+ }
75
+ return {
76
+ success: true,
77
+ writes
78
+ };
79
+ } catch (error) {
80
+ return {
81
+ reason: error instanceof Error ? error.message : 'Could not prepare TanStack files.',
82
+ success: false
83
+ };
84
+ }
85
+ }
86
+ export async function applyPreparedWrites({ writes }) {
87
+ for (const { content, filePath } of writes){
88
+ await fse.ensureDir(path.dirname(filePath));
89
+ await fse.writeFile(filePath, content);
90
+ }
91
+ }
92
+ async function getTemplateFiles({ appDetails, templateRoot }) {
93
+ const files = [];
94
+ const hasPackedTemplateLayout = await fse.pathExists(path.join(templateRoot, 'routes'));
95
+ for (const { destination, relativePath, sourcePath } of TANSTACK_TEMPLATE_FILES){
96
+ const templatePath = hasPackedTemplateLayout ? path.join(templateRoot, destination, relativePath) : path.join(templateRoot, sourcePath);
97
+ if (!await fse.pathExists(templatePath)) {
98
+ return {
99
+ reason: `Required TanStack template file is missing: ${templatePath}.`,
100
+ success: false
101
+ };
102
+ }
103
+ files.push({
104
+ filePath: path.join(destination === 'src' ? appDetails.sourceDir : appDetails.routesDir, relativePath),
105
+ templatePath
106
+ });
107
+ }
108
+ return {
109
+ files,
110
+ success: true
111
+ };
112
+ }
113
+
114
+ //# sourceMappingURL=prepare.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../src/lib/tanstack/prepare.ts"],"sourcesContent":["import fse from 'fs-extra'\nimport path from 'node:path'\n\nimport type { TanStackAppDetails } from '../../types.js'\nimport type { TextTransformResult } from './transform-vite-config.js'\n\nimport { TANSTACK_TEMPLATE_FILES } from './template-files.js'\nimport { transformTanStackRootRoute } from './transform-root-route.js'\nimport { transformTanStackRouter } from './transform-router.js'\nimport { transformTanStackViteConfig } from './transform-vite-config.js'\n\nexport type PreparedWrite = {\n /** Exact content to write after every preparation check succeeds. */\n content: string\n /** Absolute destination path in the detected host project. */\n filePath: string\n}\n\ntype PrepareResult = { reason: string; success: false } | { success: true; writes: PreparedWrite[] }\n\ntype TemplateFile = {\n filePath: string\n templatePath: string\n}\n\nexport async function prepareTanStackInit({\n appDetails,\n templateRoot,\n}: {\n appDetails: TanStackAppDetails\n templateRoot: string\n}): Promise<PrepareResult> {\n try {\n const templateFilesResult = await getTemplateFiles({ appDetails, templateRoot })\n if (!templateFilesResult.success) {\n return templateFilesResult\n }\n\n const [viteConfigContent, routerContent, rootRouteContent, ...templateContents] =\n await Promise.all([\n fse.readFile(appDetails.viteConfigPath, 'utf8'),\n fse.readFile(appDetails.routerPath, 'utf8'),\n fse.readFile(appDetails.rootRoutePath, 'utf8'),\n ...templateFilesResult.files.map(({ templatePath }) => fse.readFile(templatePath, 'utf8')),\n ])\n\n const transformedFiles: Array<{\n filePath: string\n result: TextTransformResult\n }> = [\n {\n filePath: appDetails.viteConfigPath,\n result: transformTanStackViteConfig({ appDetails, content: viteConfigContent }),\n },\n {\n filePath: appDetails.routerPath,\n result: transformTanStackRouter({ content: routerContent }),\n },\n {\n filePath: appDetails.rootRoutePath,\n result: transformTanStackRootRoute({ content: rootRouteContent, kind: appDetails.kind }),\n },\n ]\n\n const failedTransform = transformedFiles.find(({ result }) => !result.success)\n if (failedTransform && !failedTransform.result.success) {\n return {\n reason: `Could not transform ${failedTransform.filePath}: ${failedTransform.result.reason}`,\n success: false,\n }\n }\n\n const writes: PreparedWrite[] = transformedFiles.flatMap(({ filePath, result }) =>\n result.success && result.modified ? [{ content: result.content, filePath }] : [],\n )\n\n for (const [index, templateFile] of templateFilesResult.files.entries()) {\n const content = templateContents[index]!\n const { filePath } = templateFile\n\n if (await fse.pathExists(filePath)) {\n const existingContent = await fse.readFile(filePath, 'utf8')\n if (existingContent !== content) {\n return { reason: `A different file already exists at ${filePath}.`, success: false }\n }\n\n continue\n }\n\n writes.push({ content, filePath })\n }\n\n return { success: true, writes }\n } catch (error) {\n return {\n reason: error instanceof Error ? error.message : 'Could not prepare TanStack files.',\n success: false,\n }\n }\n}\n\nexport async function applyPreparedWrites({ writes }: { writes: PreparedWrite[] }): Promise<void> {\n for (const { content, filePath } of writes) {\n await fse.ensureDir(path.dirname(filePath))\n await fse.writeFile(filePath, content)\n }\n}\n\nasync function getTemplateFiles({\n appDetails,\n templateRoot,\n}: {\n appDetails: TanStackAppDetails\n templateRoot: string\n}): Promise<{ files: TemplateFile[]; success: true } | { reason: string; success: false }> {\n const files: TemplateFile[] = []\n const hasPackedTemplateLayout = await fse.pathExists(path.join(templateRoot, 'routes'))\n\n for (const { destination, relativePath, sourcePath } of TANSTACK_TEMPLATE_FILES) {\n const templatePath = hasPackedTemplateLayout\n ? path.join(templateRoot, destination, relativePath)\n : path.join(templateRoot, sourcePath)\n if (!(await fse.pathExists(templatePath))) {\n return {\n reason: `Required TanStack template file is missing: ${templatePath}.`,\n success: false,\n }\n }\n\n files.push({\n filePath: path.join(\n destination === 'src' ? appDetails.sourceDir : appDetails.routesDir,\n relativePath,\n ),\n templatePath,\n })\n }\n\n return { files, success: true }\n}\n"],"names":["fse","path","TANSTACK_TEMPLATE_FILES","transformTanStackRootRoute","transformTanStackRouter","transformTanStackViteConfig","prepareTanStackInit","appDetails","templateRoot","templateFilesResult","getTemplateFiles","success","viteConfigContent","routerContent","rootRouteContent","templateContents","Promise","all","readFile","viteConfigPath","routerPath","rootRoutePath","files","map","templatePath","transformedFiles","filePath","result","content","kind","failedTransform","find","reason","writes","flatMap","modified","index","templateFile","entries","pathExists","existingContent","push","error","Error","message","applyPreparedWrites","ensureDir","dirname","writeFile","hasPackedTemplateLayout","join","destination","relativePath","sourcePath","sourceDir","routesDir"],"mappings":"AAAA,OAAOA,SAAS,WAAU;AAC1B,OAAOC,UAAU,YAAW;AAK5B,SAASC,uBAAuB,QAAQ,sBAAqB;AAC7D,SAASC,0BAA0B,QAAQ,4BAA2B;AACtE,SAASC,uBAAuB,QAAQ,wBAAuB;AAC/D,SAASC,2BAA2B,QAAQ,6BAA4B;AAgBxE,OAAO,eAAeC,oBAAoB,EACxCC,UAAU,EACVC,YAAY,EAIb;IACC,IAAI;QACF,MAAMC,sBAAsB,MAAMC,iBAAiB;YAAEH;YAAYC;QAAa;QAC9E,IAAI,CAACC,oBAAoBE,OAAO,EAAE;YAChC,OAAOF;QACT;QAEA,MAAM,CAACG,mBAAmBC,eAAeC,kBAAkB,GAAGC,iBAAiB,GAC7E,MAAMC,QAAQC,GAAG,CAAC;YAChBjB,IAAIkB,QAAQ,CAACX,WAAWY,cAAc,EAAE;YACxCnB,IAAIkB,QAAQ,CAACX,WAAWa,UAAU,EAAE;YACpCpB,IAAIkB,QAAQ,CAACX,WAAWc,aAAa,EAAE;eACpCZ,oBAAoBa,KAAK,CAACC,GAAG,CAAC,CAAC,EAAEC,YAAY,EAAE,GAAKxB,IAAIkB,QAAQ,CAACM,cAAc;SACnF;QAEH,MAAMC,mBAG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ativePath: '_payload.tsx';
4
+ readonly sourcePath: 'app/_payload.tsx';
5
+ }, {
6
+ readonly destination: 'routes';
7
+ readonly relativePath: '_payload/admin.$.tsx';
8
+ readonly sourcePath: 'app/_payload/admin.$.tsx';
9
+ }, {
10
+ readonly destination: 'routes';
11
+ readonly relativePath: '_payload/admin.index.tsx';
12
+ readonly sourcePath: 'app/_payload/admin.index.tsx';
13
+ }, {
14
+ readonly destination: 'routes';
15
+ readonly relativePath: '_payload/api.$.ts';
16
+ readonly sourcePath: 'app/_payload/api.$.ts';
17
+ }, {
18
+ readonly destination: 'routes';
19
+ readonly relativePath: '_payload/importMap.js';
20
+ readonly sourcePath: 'app/_payload/importMap.js';
21
+ }, {
22
+ readonly destination: 'routes';
23
+ readonly relativePath: '_payload/server.functions.ts';
24
+ readonly sourcePath: 'app/_payload/server.functions.ts';
25
+ }, {
26
+ readonly destination: 'src';
27
+ readonly relativePath: 'collections/Folders.ts';
28
+ readonly sourcePath: 'collections/Folders.ts';
29
+ }, {
30
+ readonly destination: 'src';
31
+ readonly relativePath: 'collections/Media.ts';
32
+ readonly sourcePath: 'collections/Media.ts';
33
+ }, {
34
+ readonly destination: 'src';
35
+ readonly relativePath: 'collections/Tags.ts';
36
+ readonly sourcePath: 'collections/Tags.ts';
37
+ }, {
38
+ readonly destination: 'src';
39
+ readonly relativePath: 'collections/Users.ts';
40
+ readonly sourcePath: 'collections/Users.ts';
41
+ }, {
42
+ readonly destination: 'src';
43
+ readonly relativePath: 'payload.css';
44
+ readonly sourcePath: 'payload.css';
45
+ }, {
46
+ readonly destination: 'src';
47
+ readonly relativePath: 'payload.config.ts';
48
+ readonly sourcePath: 'payload.config.ts';
49
+ }];
50
+ //# sourceMappingURL=template-files.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"template-files.d.ts","sourceRoot":"","sources":["../../../src/lib/tanstack/template-files.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,uBAAuB;aAEhC,WAAW,EAAE,QAAQ;aACrB,YAAY,EAAE,cAAc;aAC5B,UAAU,EAAE,kBAAkB;;aAG9B,WAAW,EAAE,QAAQ;aACrB,YAAY,EAAE,sBAAsB;aACpC,UAAU,EAAE,0BAA0B;;aAGtC,WAAW,EAAE,QAAQ;aACrB,YAAY,EAAE,0BAA0B;aACxC,UAAU,EAAE,8BAA8B;;aAG1C,WAAW,EAAE,QAAQ;aACrB,YAAY,EAAE,mBAAmB;aACjC,UAAU,EAAE,uBAAuB;;aAGnC,WAAW,EAAE,QAAQ;aACrB,YAAY,EAAE,uBAAuB;aACrC,UAAU,EAAE,2BAA2B;;aAGvC,WAAW,EAAE,QAAQ;aACrB,YAAY,EAAE,8BAA8B;aAC5C,UAAU,EAAE,kCAAkC;;aAG9C,WAAW,EAAE,KAAK;aAClB,YAAY,EAAE,wBAAwB;aACtC,UAAU,EAAE,wBAAwB;;aAGpC,WAAW,EAAE,KAAK;aAClB,YAAY,EAAE,sBAAsB;aACpC,UAAU,EAAE,sBAAsB;;aAGlC,WAAW,EAAE,KAAK;aAClB,YAAY,EAAE,qBAAqB;aACnC,UAAU,EAAE,qBAAqB;;aAGjC,WAAW,EAAE,KAAK;aAClB,YAAY,EAAE,sBAAsB;aACpC,UAAU,EAAE,sBAAsB;;aAGlC,WAAW,EAAE,KAAK;aAClB,YAAY,EAAE,aAAa;aAC3B,UAAU,EAAE,aAAa;;aAGzB,WAAW,EAAE,KAAK;aAClB,YAAY,EAAE,mBAAmB;aACjC,UAAU,EAAE,mBAAmB;EAEzB,CAAA"}
@@ -0,0 +1,64 @@
1
+ export const TANSTACK_TEMPLATE_FILES = [
2
+ {
3
+ destination: 'routes',
4
+ relativePath: '_payload.tsx',
5
+ sourcePath: 'app/_payload.tsx'
6
+ },
7
+ {
8
+ destination: 'routes',
9
+ relativePath: '_payload/admin.$.tsx',
10
+ sourcePath: 'app/_payload/admin.$.tsx'
11
+ },
12
+ {
13
+ destination: 'routes',
14
+ relativePath: '_payload/admin.index.tsx',
15
+ sourcePath: 'app/_payload/admin.index.tsx'
16
+ },
17
+ {
18
+ destination: 'routes',
19
+ relativePath: '_payload/api.$.ts',
20
+ sourcePath: 'app/_payload/api.$.ts'
21
+ },
22
+ {
23
+ destination: 'routes',
24
+ relativePath: '_payload/importMap.js',
25
+ sourcePath: 'app/_payload/importMap.js'
26
+ },
27
+ {
28
+ destination: 'routes',
29
+ relativePath: '_payload/server.functions.ts',
30
+ sourcePath: 'app/_payload/server.functions.ts'
31
+ },
32
+ {
33
+ destination: 'src',
34
+ relativePath: 'collections/Folders.ts',
35
+ sourcePath: 'collections/Folders.ts'
36
+ },
37
+ {
38
+ destination: 'src',
39
+ relativePath: 'collections/Media.ts',
40
+ sourcePath: 'collections/Media.ts'
41
+ },
42
+ {
43
+ destination: 'src',
44
+ relativePath: 'collections/Tags.ts',
45
+ sourcePath: 'collections/Tags.ts'
46
+ },
47
+ {
48
+ destination: 'src',
49
+ relativePath: 'collections/Users.ts',
50
+ sourcePath: 'collections/Users.ts'
51
+ },
52
+ {
53
+ destination: 'src',
54
+ relativePath: 'payload.css',
55
+ sourcePath: 'payload.css'
56
+ },
57
+ {
58
+ destination: 'src',
59
+ relativePath: 'payload.config.ts',
60
+ sourcePath: 'payload.config.ts'
61
+ }
62
+ ];
63
+
64
+ //# sourceMappingURL=template-files.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../src/lib/tanstack/template-files.ts"],"sourcesContent":["export const TANSTACK_TEMPLATE_FILES = [\n {\n destination: 'routes',\n relativePath: '_payload.tsx',\n sourcePath: 'app/_payload.tsx',\n },\n {\n destination: 'routes',\n relativePath: '_payload/admin.$.tsx',\n sourcePath: 'app/_payload/admin.$.tsx',\n },\n {\n destination: 'routes',\n relativePath: '_payload/admin.index.tsx',\n sourcePath: 'app/_payload/admin.index.tsx',\n },\n {\n destination: 'routes',\n relativePath: '_payload/api.$.ts',\n sourcePath: 'app/_payload/api.$.ts',\n },\n {\n destination: 'routes',\n relativePath: '_payload/importMap.js',\n sourcePath: 'app/_payload/importMap.js',\n },\n {\n destination: 'routes',\n relativePath: '_payload/server.functions.ts',\n sourcePath: 'app/_payload/server.functions.ts',\n },\n {\n destination: 'src',\n relativePath: 'collections/Folders.ts',\n sourcePath: 'collections/Folders.ts',\n },\n {\n destination: 'src',\n relativePath: 'collections/Media.ts',\n sourcePath: 'collections/Media.ts',\n },\n {\n destination: 'src',\n relativePath: 'collections/Tags.ts',\n sourcePath: 'collections/Tags.ts',\n },\n {\n destination: 'src',\n relativePath: 'collections/Users.ts',\n sourcePath: 'collections/Users.ts',\n },\n {\n destination: 'src',\n relativePath: 'payload.css',\n sourcePath: 'payload.css',\n },\n {\n destination: 'src',\n relativePath: 'payload.config.ts',\n sourcePath: 'payload.config.ts',\n },\n] as const\n"],"names":["TANSTACK_TEMPLATE_FILES","destination","relativePath","sourcePath"],"mappings":"AAAA,OAAO,MAAMA,0BAA0B;IACrC;QACEC,aAAa;QACbC,cAAc;QACdC,YAAY;IACd;IACA;QACEF,aAAa;QACbC,cAAc;QACdC,YAAY;IACd;IACA;QACEF,aAAa;QACbC,cAAc;QACdC,YAAY;IACd;IACA;QACEF,aAAa;QACbC,cAAc;QACdC,YAAY;IACd;IACA;QACEF,aAAa;QACbC,cAAc;QACdC,YAAY;IACd;IACA;QACEF,aAAa;QACbC,cAAc;QACdC,YAAY;IACd;IACA;QACEF,aAAa;QACbC,cAAc;QACdC,YAAY;IACd;IACA;QACEF,aAAa;QACbC,cAAc;QACdC,YAAY;IACd;IACA;QACEF,aAAa;QACbC,cAAc;QACdC,YAAY;IACd;IACA;QACEF,aAAa;QACbC,cAAc;QACdC,YAAY;IACd;IACA;QACEF,aAAa;QACbC,cAAc;QACdC,YAAY;IACd;IACA;QACEF,aAAa;QACbC,cAAc;QACdC,YAAY;IACd;CACD,CAAS"}
@@ -0,0 +1,7 @@
1
+ import type { TanStackAppDetails } from '../../types.js';
2
+ import type { TextTransformResult } from './transform-vite-config.js';
3
+ export declare function transformTanStackRootRoute({ content, kind, }: {
4
+ content: string;
5
+ kind: TanStackAppDetails['kind'];
6
+ }): TextTransformResult;
7
+ //# sourceMappingURL=transform-root-route.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"transform-root-route.d.ts","sourceRoot":"","sources":["../../../src/lib/tanstack/transform-root-route.ts"],"names":[],"mappings":"AAgBA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,gBAAgB,CAAA;AACxD,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,4BAA4B,CAAA;AAkBrE,wBAAgB,0BAA0B,CAAC,EACzC,OAAO,EACP,IAAI,GACL,EAAE;IACD,OAAO,EAAE,MAAM,CAAA;IACf,IAAI,EAAE,kBAAkB,CAAC,MAAM,CAAC,CAAA;CACjC,GAAG,mBAAmB,CAyCtB"}