We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I decided to go mjs way instead of type: module, but umzug can't handle these files atm.
mjs
type: module
require doesn't work with esm so then maybe it would be nice to make resolver async so I can handle these files with dynamic import.
Now I made it work like this:
resolve: ({ name, path, context }) => { return { // adjust the parameters Umzug will // pass to migration methods when called name, up: async () => { const { up } = await import(path); return up({ context }); }, down: async () => { const { down } = await import(path); return down({ context }); }, }; },
Thanks
The text was updated successfully, but these errors were encountered:
Closing in favour of #608
Sorry, something went wrong.
No branches or pull requests
I decided to go
mjs
way instead oftype: module
, but umzug can't handle these files atm.require doesn't work with esm so then maybe it would be nice to make resolver async so I can handle these files with dynamic import.
Now I made it work like this:
Thanks
The text was updated successfully, but these errors were encountered: