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
Is your feature request related to a problem? Please describe.
It would be nice to not require typescript installed globally when yarn add/npm installing this package.
Describe the solution you'd like
running tsc -p tsconfig.json in the prepare script instead of the postinstall should have access to the node_modules folder. Also including typescript (or tsc) as a dev dependency will be required. This way the tsc command will reference typescript from the node_modules folder.
Describe alternatives you've considered
none
Additional context
sorry if this has been tried before, but I suppose there has to be a way to not require the consuming project to have global node modules installed.
The text was updated successfully, but these errors were encountered:
I agree with the above ^ request. You should generally avoid publishing files that need to be compiled/transpiled in order for the package to be used. Please consider compiling your typescript into a /dist folder, then only publish the contents of the /dist folder to npm. This can be accomplished via .npmignore and/or the package.json "files" attribute.
Edit:
I came here because this broke my build pipeline, because this particular project Im working on is not using typescript, which is why tsc wasn't installed on the build server.
Is your feature request related to a problem? Please describe.
It would be nice to not require typescript installed globally when
yarn add
/npm install
ing this package.Describe the solution you'd like
running
tsc -p tsconfig.json
in theprepare
script instead of thepostinstall
should have access to the node_modules folder. Also including typescript (or tsc) as a dev dependency will be required. This way thetsc
command will reference typescript from the node_modules folder.Describe alternatives you've considered
none
Additional context
sorry if this has been tried before, but I suppose there has to be a way to not require the consuming project to have global node modules installed.
The text was updated successfully, but these errors were encountered: