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
If a repository is full-ESM (type="module" in package.json)
The following scenario fail.
configuration file in ESM, extension js
Error [ERR_REQUIRE_ESM]: require() of ES Module pix/api/tests/acceptance/database/configuration.js from pix/api/node_modules/schemalint/build/cli.js not supported.
configuration file in CJS, extension js
Error [ERR_REQUIRE_ESM]: require() of ES Module /pix/api/tests/acceptance/database/configuration.js from pix/api/node_modules/schemalint/build/cli.js not supported.
configuration.js is treated as an ES module file as it is a .js file whose nearest parent package.json contains "type": "module"
A following scenario works:
a configuration file in CJS, extension cjs:
a invocation using this file schemalint --config tests/acceptance/database/configuration.cjs
It would be much useful to mention it in documentation.
The text was updated successfully, but these errors were encountered:
If a repository is full-ESM (
type="module"
inpackage.json
)The following scenario fail.
js
js
A following scenario works:
cjs
:schemalint --config tests/acceptance/database/configuration.cjs
It would be much useful to mention it in documentation.
The text was updated successfully, but these errors were encountered: