Closed ainsleyclark closed 1 month ago
You guys can close this, because its not actually a payloadcms issue but a VS code configuration issue or IDE configuration issue.
You have to make sure your IDE like VScode is using the workspace TS version as its language server, not the global language server, I had my VSCode set to TS 5.5 and it causes this error. Make sure it uses the workspace ts server.
Thanks for the explanation @TomDo1234
@TomDo1234 is right, it's recommended to use a TS version from the workspace, closing this as seems like resolved.
This issue has been automatically locked. Please open a new issue if this issue persists with any additional detail.
Link to reproduction
https://github.com/ainsleydev/go-payloadcms/tree/main/dev
Describe the Bug
When creating a migration, errors occur within the TS migration files:
It then creates the migration files, but the Typscript it generates doesn't look quite right (screenshot attached) So when pnpm run build is ran I get this:
To Reproduce
Run
pnpm run payload migrate:create
from the repo provided.Payload Version
2.18.3
Adapters and Plugins
Postgres DB