openapi-nodejs-sdk icon indicating copy to clipboard operation
openapi-nodejs-sdk copied to clipboard

Incompatibility with ES Modules (type: "module") [Node 20+]

Open francescobianco opened this issue 1 year ago • 0 comments

Using import Openapi from 'openapi-sdk' in an ESM project triggers a SyntaxError: Cannot use import statement outside a module. Context: Node 20+, "type": "module" set in package.json. Workaround: Use require('openapi-sdk').default, but this breaks linting.

francescobianco avatar Nov 09 '25 14:11 francescobianco