create-payload-app 3.0.0-beta.9 → 3.0.0-canary.0d307b1
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/lib/configure-payload-config.d.ts +8 -2
- package/dist/lib/configure-payload-config.d.ts.map +1 -1
- package/dist/lib/configure-payload-config.js +96 -21
- package/dist/lib/configure-payload-config.js.map +1 -1
- package/dist/lib/create-project.d.ts.map +1 -1
- package/dist/lib/create-project.js +9 -2
- package/dist/lib/create-project.js.map +1 -1
- package/dist/lib/create-project.spec.js +9 -12
- package/dist/lib/create-project.spec.js.map +1 -1
- package/dist/lib/get-package-manager.d.ts +6 -0
- package/dist/lib/get-package-manager.d.ts.map +1 -0
- package/dist/lib/get-package-manager.js +29 -0
- package/dist/lib/get-package-manager.js.map +1 -0
- package/dist/lib/init-next.d.ts +1 -9
- package/dist/lib/init-next.d.ts.map +1 -1
- package/dist/lib/init-next.js +34 -51
- package/dist/lib/init-next.js.map +1 -1
- package/dist/lib/install-packages.d.ts +9 -0
- package/dist/lib/install-packages.d.ts.map +1 -0
- package/dist/lib/install-packages.js +43 -0
- package/dist/lib/install-packages.js.map +1 -0
- package/dist/lib/replacements.d.ts +27 -0
- package/dist/lib/replacements.d.ts.map +1 -0
- package/dist/lib/replacements.js +68 -0
- package/dist/lib/replacements.js.map +1 -0
- package/dist/lib/select-db.js +1 -1
- package/dist/lib/select-db.js.map +1 -1
- package/dist/lib/templates.js +1 -1
- package/dist/lib/templates.js.map +1 -1
- package/dist/lib/update-payload-in-project.d.ts +6 -0
- package/dist/lib/update-payload-in-project.d.ts.map +1 -0
- package/dist/lib/update-payload-in-project.js +71 -0
- package/dist/lib/update-payload-in-project.js.map +1 -0
- package/dist/lib/wrap-next-config.d.ts.map +1 -1
- package/dist/lib/wrap-next-config.js +1 -2
- package/dist/lib/wrap-next-config.js.map +1 -1
- package/dist/lib/wrap-next-config.spec.js +1 -0
- package/dist/lib/wrap-next-config.spec.js.map +1 -1
- package/dist/main.d.ts.map +1 -1
- package/dist/main.js +28 -21
- package/dist/main.js.map +1 -1
- package/dist/template/src/app/(payload)/admin/[[...segments]]/not-found.tsx +22 -0
- package/dist/template/src/app/(payload)/admin/[[...segments]]/page.tsx +6 -1
- package/dist/template/src/app/(payload)/api/[...slug]/route.ts +2 -1
- package/dist/template/src/collections/Media.ts +16 -0
- package/dist/template/src/collections/Users.ts +1 -1
- package/dist/template/src/payload.config.ts +11 -15
- package/dist/types.d.ts +11 -0
- package/dist/types.d.ts.map +1 -1
- package/dist/types.js.map +1 -1
- package/dist/utils/copy-recursive-sync.d.ts +2 -0
- package/dist/utils/copy-recursive-sync.d.ts.map +1 -1
- package/dist/utils/copy-recursive-sync.js +2 -0
- package/dist/utils/copy-recursive-sync.js.map +1 -1
- package/dist/utils/git.d.ts +4 -0
- package/dist/utils/git.d.ts.map +1 -0
- package/dist/utils/git.js +46 -0
- package/dist/utils/git.js.map +1 -0
- package/dist/utils/messages.d.ts.map +1 -1
- package/dist/utils/messages.js.map +1 -1
- package/package.json +34 -22
- package/dist/lib/packages.d.ts +0 -9
- package/dist/lib/packages.d.ts.map +0 -1
- package/dist/lib/packages.js +0 -27
- package/dist/lib/packages.js.map +0 -1
package/package.json
CHANGED
@@ -1,17 +1,38 @@
|
|
1
1
|
{
|
2
2
|
"name": "create-payload-app",
|
3
|
-
"version": "3.0.0-
|
4
|
-
"license": "MIT",
|
5
|
-
"type": "module",
|
3
|
+
"version": "3.0.0-canary.0d307b1",
|
6
4
|
"homepage": "https://payloadcms.com",
|
7
|
-
"bin": {
|
8
|
-
"create-payload-app": "bin/cli.js"
|
9
|
-
},
|
10
5
|
"repository": {
|
11
6
|
"type": "git",
|
12
7
|
"url": "https://github.com/payloadcms/payload.git",
|
13
8
|
"directory": "packages/create-payload-app"
|
14
9
|
},
|
10
|
+
"license": "MIT",
|
11
|
+
"type": "module",
|
12
|
+
"exports": {
|
13
|
+
"./types": {
|
14
|
+
"import": "./src/types.ts",
|
15
|
+
"require": "./src/types.ts"
|
16
|
+
},
|
17
|
+
"./commands": {
|
18
|
+
"import": "./src/lib/init-next.ts",
|
19
|
+
"require": "./src/lib/init-next.ts",
|
20
|
+
"types": "./src/lib/init-next.ts"
|
21
|
+
},
|
22
|
+
"./lib/*": {
|
23
|
+
"import": "./src/lib/*",
|
24
|
+
"require": "./src/lib/*",
|
25
|
+
"types": "./src/lib/*"
|
26
|
+
},
|
27
|
+
"./utils/*": {
|
28
|
+
"import": "./src/utils/*",
|
29
|
+
"require": "./src/utils/*",
|
30
|
+
"types": "./src/utils/*"
|
31
|
+
}
|
32
|
+
},
|
33
|
+
"bin": {
|
34
|
+
"create-payload-app": "bin/cli.js"
|
35
|
+
},
|
15
36
|
"files": [
|
16
37
|
"package.json",
|
17
38
|
"dist",
|
@@ -22,10 +43,8 @@
|
|
22
43
|
"@sindresorhus/slugify": "^1.1.0",
|
23
44
|
"arg": "^5.0.0",
|
24
45
|
"chalk": "^4.1.0",
|
25
|
-
"command-exists": "^1.2.9",
|
26
46
|
"comment-json": "^4.2.3",
|
27
47
|
"degit": "^2.8.4",
|
28
|
-
"detect-package-manager": "^3.0.1",
|
29
48
|
"esprima-next": "^6.0.3",
|
30
49
|
"execa": "^5.0.0",
|
31
50
|
"figures": "^6.1.0",
|
@@ -34,26 +53,19 @@
|
|
34
53
|
"terminal-link": "^2.1.1"
|
35
54
|
},
|
36
55
|
"devDependencies": {
|
37
|
-
"@types/command-exists": "^1.2.0",
|
38
56
|
"@types/degit": "^2.8.3",
|
39
57
|
"@types/esprima": "^4.0.6",
|
40
58
|
"@types/fs-extra": "^9.0.12",
|
41
|
-
"@types/jest": "
|
42
|
-
"@types/node": "20.12.5"
|
43
|
-
|
44
|
-
"exports": {
|
45
|
-
"./commands": {
|
46
|
-
"import": "./src/lib/init-next.ts",
|
47
|
-
"require": "./src/lib/init-next.ts",
|
48
|
-
"types": "./src/lib/init-next.ts"
|
49
|
-
}
|
59
|
+
"@types/jest": "29.5.12",
|
60
|
+
"@types/node": "20.12.5",
|
61
|
+
"temp-dir": "2.0.0"
|
50
62
|
},
|
51
63
|
"scripts": {
|
52
64
|
"build": "pnpm pack-template-files && pnpm typecheck && pnpm build:swc",
|
53
|
-
"
|
54
|
-
"pack-template-files": "tsx src/scripts/pack-template-files.ts",
|
55
|
-
"build:swc": "swc ./src -d ./dist --config-file .swcrc",
|
65
|
+
"build:swc": "swc ./src -d ./dist --config-file .swcrc --strip-leading-paths",
|
56
66
|
"clean": "rimraf {dist,*.tsbuildinfo}",
|
57
|
-
"
|
67
|
+
"pack-template-files": "tsx src/scripts/pack-template-files.ts",
|
68
|
+
"test": "jest",
|
69
|
+
"typecheck": "tsc"
|
58
70
|
}
|
59
71
|
}
|
package/dist/lib/packages.d.ts
DELETED
@@ -1,9 +0,0 @@
|
|
1
|
-
import type { DbType } from '../types.js';
|
2
|
-
type DbAdapterReplacement = {
|
3
|
-
configReplacement: string[];
|
4
|
-
importReplacement: string;
|
5
|
-
packageName: string;
|
6
|
-
};
|
7
|
-
export declare const dbReplacements: Record<DbType, DbAdapterReplacement>;
|
8
|
-
export {};
|
9
|
-
//# sourceMappingURL=packages.d.ts.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"packages.d.ts","sourceRoot":"","sources":["../../src/lib/packages.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,aAAa,CAAA;AAEzC,KAAK,oBAAoB,GAAG;IAC1B,iBAAiB,EAAE,MAAM,EAAE,CAAA;IAC3B,iBAAiB,EAAE,MAAM,CAAA;IACzB,WAAW,EAAE,MAAM,CAAA;CACpB,CAAA;AAyBD,eAAO,MAAM,cAAc,EAAE,MAAM,CAAC,MAAM,EAAE,oBAAoB,CAG/D,CAAA"}
|
package/dist/lib/packages.js
DELETED
@@ -1,27 +0,0 @@
|
|
1
|
-
const mongodbReplacement = {
|
2
|
-
importReplacement: "import { mongooseAdapter } from '@payloadcms/db-mongodb'",
|
3
|
-
packageName: '@payloadcms/db-mongodb',
|
4
|
-
// Replacement between `// database-adapter-config-start` and `// database-adapter-config-end`
|
5
|
-
configReplacement: [
|
6
|
-
' db: mongooseAdapter({',
|
7
|
-
" url: process.env.DATABASE_URI || '',",
|
8
|
-
' }),'
|
9
|
-
]
|
10
|
-
};
|
11
|
-
const postgresReplacement = {
|
12
|
-
configReplacement: [
|
13
|
-
' db: postgresAdapter({',
|
14
|
-
' pool: {',
|
15
|
-
" connectionString: process.env.DATABASE_URI || '',",
|
16
|
-
' },',
|
17
|
-
' }),'
|
18
|
-
],
|
19
|
-
importReplacement: "import { postgresAdapter } from '@payloadcms/db-postgres'",
|
20
|
-
packageName: '@payloadcms/db-postgres'
|
21
|
-
};
|
22
|
-
export const dbReplacements = {
|
23
|
-
mongodb: mongodbReplacement,
|
24
|
-
postgres: postgresReplacement
|
25
|
-
};
|
26
|
-
|
27
|
-
//# sourceMappingURL=packages.js.map
|
package/dist/lib/packages.js.map
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"sources":["../../src/lib/packages.ts"],"sourcesContent":["import type { DbType } from '../types.js'\n\ntype DbAdapterReplacement = {\n configReplacement: string[]\n importReplacement: string\n packageName: string\n}\n\nconst mongodbReplacement: DbAdapterReplacement = {\n importReplacement: \"import { mongooseAdapter } from '@payloadcms/db-mongodb'\",\n packageName: '@payloadcms/db-mongodb',\n // Replacement between `// database-adapter-config-start` and `// database-adapter-config-end`\n configReplacement: [\n ' db: mongooseAdapter({',\n \" url: process.env.DATABASE_URI || '',\",\n ' }),',\n ],\n}\n\nconst postgresReplacement: DbAdapterReplacement = {\n configReplacement: [\n ' db: postgresAdapter({',\n ' pool: {',\n \" connectionString: process.env.DATABASE_URI || '',\",\n ' },',\n ' }),',\n ],\n importReplacement: \"import { postgresAdapter } from '@payloadcms/db-postgres'\",\n packageName: '@payloadcms/db-postgres',\n}\n\nexport const dbReplacements: Record<DbType, DbAdapterReplacement> = {\n mongodb: mongodbReplacement,\n postgres: postgresReplacement,\n}\n"],"names":["mongodbReplacement","importReplacement","packageName","configReplacement","postgresReplacement","dbReplacements","mongodb","postgres"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;","mappings":"AAQA,MAAMA,qBAA2C;IAC/CC,mBAAmB;IACnBC,aAAa;IACb,8FAA8F;IAC9FC,mBAAmB;QACjB;QACA;QACA;KACD;AACH;AAEA,MAAMC,sBAA4C;IAChDD,mBAAmB;QACjB;QACA;QACA;QACA;QACA;KACD;IACDF,mBAAmB;IACnBC,aAAa;AACf;AAEA,OAAO,MAAMG,iBAAuD;IAClEC,SAASN;IACTO,UAAUH;AACZ,EAAC"}
|