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
My Typescript linting is complaining with 'parameters.ts' cannot be compiled under '--isolatedModules' because it is considered a global script file. Add an import, export, or an empty 'export {}' statement to make it a module.. That's because the parameters.ts is generated empty:
/**
* Generated by @openapi-codegen
*
* @version 0.0.0
*/
My workaround is to append export {} to make it passes, but it's annoying since it comes back at each generation.
There are multiple solutions:
In the openapi-codegen.config.ts after the generation I override the file automatically if no export detected
I turn off isolatedModules in my tsconfig (not a huge fan)
I ignore this file during the linting (not a huge fan)
See with you if it can be improved 😄
It seems I'm the only one reporting this, maybe I'm doing something wrong?
Thank you,
The text was updated successfully, but these errors were encountered:
Hi @fabien0102,
My Typescript linting is complaining with
'parameters.ts' cannot be compiled under '--isolatedModules' because it is considered a global script file. Add an import, export, or an empty 'export {}' statement to make it a module.
. That's because theparameters.ts
is generated empty:My workaround is to append
export {}
to make it passes, but it's annoying since it comes back at each generation.There are multiple solutions:
openapi-codegen.config.ts
after the generation I override the file automatically if no export detectedisolatedModules
in my tsconfig (not a huge fan)It seems I'm the only one reporting this, maybe I'm doing something wrong?
Thank you,
The text was updated successfully, but these errors were encountered: