Merge branch 'alpha' of https://github.com/payloadcms/payload into fix/zhTW-translations

This commit is contained in:
PatrikKozak
2024-04-08 17:21:16 -04:00
4 changed files with 13 additions and 7 deletions

View File

@@ -10,6 +10,6 @@
}
},
"module": {
"type": "commonjs"
"type": "es6"
}
}

View File

@@ -1,2 +1,4 @@
#!/usr/bin/env node
require('../dist/index.js')
import { main } from '../dist/index.js'
main()

View File

@@ -1,6 +1,6 @@
{
"name": "create-payload-app",
"version": "3.0.0-alpha.54",
"version": "3.0.0-alpha.59",
"license": "MIT",
"type": "module",
"homepage": "https://payloadcms.com",

View File

@@ -1,8 +1,12 @@
import { Main } from './main.js'
import { error } from './utils/log.js'
async function main(): Promise<void> {
await new Main().init()
export async function main(): Promise<void> {
try {
await new Main().init()
} catch (e) {
if (e instanceof Error) {
error(e.message)
}
}
}
main().catch((e) => error(`An error has occurred: ${e instanceof Error ? e.message : e}`))