create-payload-app 3.0.0-canary.cee5702 → 3.0.0-canary.e9f7ce1
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/index.js.map +1 -1
- 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 +74 -25
- 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 +1 -1
- package/dist/lib/create-project.js.map +1 -1
- package/dist/lib/create-project.spec.js +3 -2
- package/dist/lib/create-project.spec.js.map +1 -1
- package/dist/lib/generate-secret.js.map +1 -1
- package/dist/lib/get-package-manager.js.map +1 -1
- package/dist/lib/init-next.js.map +1 -1
- package/dist/lib/install-packages.js.map +1 -1
- package/dist/lib/parse-project-name.js.map +1 -1
- package/dist/lib/parse-template.js.map +1 -1
- 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.map +1 -1
- package/dist/lib/templates.js.map +1 -1
- package/dist/lib/update-payload-in-project.js.map +1 -1
- 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/lib/write-env-file.js.map +1 -1
- package/dist/main.js +2 -2
- package/dist/main.js.map +1 -1
- package/dist/scripts/pack-template-files.js.map +1 -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 +10 -15
- package/dist/types.d.ts +1 -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.js.map +1 -1
- package/dist/utils/log.js.map +1 -1
- package/dist/utils/messages.d.ts.map +1 -1
- package/dist/utils/messages.js.map +1 -1
- package/package.json +17 -3
- 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,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "create-payload-app",
|
3
|
-
"version": "3.0.0-canary.
|
3
|
+
"version": "3.0.0-canary.e9f7ce1",
|
4
4
|
"homepage": "https://payloadcms.com",
|
5
5
|
"repository": {
|
6
6
|
"type": "git",
|
@@ -10,10 +10,24 @@
|
|
10
10
|
"license": "MIT",
|
11
11
|
"type": "module",
|
12
12
|
"exports": {
|
13
|
+
"./types": {
|
14
|
+
"import": "./src/types.ts",
|
15
|
+
"require": "./src/types.ts"
|
16
|
+
},
|
13
17
|
"./commands": {
|
14
18
|
"import": "./src/lib/init-next.ts",
|
15
19
|
"require": "./src/lib/init-next.ts",
|
16
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/*"
|
17
31
|
}
|
18
32
|
},
|
19
33
|
"bin": {
|
@@ -42,13 +56,13 @@
|
|
42
56
|
"@types/degit": "^2.8.3",
|
43
57
|
"@types/esprima": "^4.0.6",
|
44
58
|
"@types/fs-extra": "^9.0.12",
|
45
|
-
"@types/jest": "
|
59
|
+
"@types/jest": "29.5.12",
|
46
60
|
"@types/node": "20.12.5",
|
47
61
|
"temp-dir": "2.0.0"
|
48
62
|
},
|
49
63
|
"scripts": {
|
50
64
|
"build": "pnpm pack-template-files && pnpm typecheck && pnpm build:swc",
|
51
|
-
"build:swc": "swc ./src -d ./dist --config-file .swcrc",
|
65
|
+
"build:swc": "swc ./src -d ./dist --config-file .swcrc --strip-leading-paths",
|
52
66
|
"clean": "rimraf {dist,*.tsbuildinfo}",
|
53
67
|
"pack-template-files": "tsx src/scripts/pack-template-files.ts",
|
54
68
|
"test": "jest",
|
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"}
|