Generate types before building payload
Some checks failed
continuous-integration/drone/push Build is failing

This commit is contained in:
tobias 2024-05-21 12:22:55 +02:00
parent cc0a5cb1c5
commit 91073bd498

View File

@ -6,9 +6,9 @@
"license": "MIT", "license": "MIT",
"scripts": { "scripts": {
"dev": "cross-env PAYLOAD_CONFIG_PATH=src/payload.config.ts nodemon", "dev": "cross-env PAYLOAD_CONFIG_PATH=src/payload.config.ts nodemon",
"build:payload": "cross-env PAYLOAD_CONFIG_PATH=src/payload.config.ts node -r tsconfig-paths/register node_modules/payload/dist/bin/index.js build", "build:payload": "cross-env PAYLOAD_CONFIG_PATH=src/payload.config.ts node -r tsconfig-paths/register node_modules/payload/dist/bin/index.js build ",
"build:server": "tsc", "build:server": "tsc",
"build": "yarn build:payload && yarn build:server", "build": "yarn build:payload && yarn generate:types && yarn build:server",
"serve": "cross-env PAYLOAD_CONFIG_PATH=dist/payload.config.js node -r tsconfig-paths/register dist/server.js", "serve": "cross-env PAYLOAD_CONFIG_PATH=dist/payload.config.js node -r tsconfig-paths/register dist/server.js",
"generate:types": "cross-env PAYLOAD_CONFIG_PATH=src/payload.config.ts node -r tsconfig-paths/register node_modules/payload/dist/bin/index.js generate:types", "generate:types": "cross-env PAYLOAD_CONFIG_PATH=src/payload.config.ts node -r tsconfig-paths/register node_modules/payload/dist/bin/index.js generate:types",
"generate:types:listen": "nodemon --watch src --ext ts --exec 'npm run generate:types'" "generate:types:listen": "nodemon --watch src --ext ts --exec 'npm run generate:types'"