You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
serialize-error version 9 uses "type": "module" in its package.json but this library uses (after it is compiled) require to load that module. This returns the following error.
.../node_modules/slonik-interceptor-query-logging/node_modules/serialize-error/index.js:1
Error [ERR_REQUIRE_ESM]: Must use import to load ES Module: .../node_modules/slonik-interceptor-query-logging/node_modules/serialize-error/index.js
require() of ES modules is not supported.
require() of .../node_modules/slonik-interceptor-query-logging/node_modules/serialize-error/index.js from .../node_modules/slonik-interceptor-query-logging/dist/src/factories/createQueryLoggingInterceptor.js is an ES module file as it is a .js file whose nearest parent package.json contains "type": "module" which defines all .js files in that package scope as ES modules.
Instead rename index.js to end in .cjs, change the requiring code to use import(), or remove "type": "module" from .../node_modules/slonik-interceptor-query-logging/node_modules/serialize-error/package.json.
at new NodeError (internal/errors.js:322:7)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1102:13) {
code: 'ERR_REQUIRE_ESM'
}
serialize-error version 9 uses
"type": "module"
in its package.json but this library uses (after it is compiled) require to load that module. This returns the following error.I guess the simplest fix would be to use version 8.1.0 of serialize-error instead of version 9.0.0. See https://gist.github.com/sindresorhus/a39789f98801d908bbc7ff3ecc99d99c
The text was updated successfully, but these errors were encountered: