Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't Install react-toggle-component "sh: 1: tsc: not found" #20

Closed
seyedasfar opened this issue Sep 21, 2019 · 2 comments
Closed

Can't Install react-toggle-component "sh: 1: tsc: not found" #20

seyedasfar opened this issue Sep 21, 2019 · 2 comments

Comments

@seyedasfar
Copy link

seyedasfar commented Sep 21, 2019

Ubuntu 19.04
Node 12.10.0
Npm 6.11.2

After npm i react-toggle-component, got this error

usama@usama-Aspire-V5-471:~/Documents/Droovia$ sudo npm i react-toggle-component

> styled-components@4.3.2 postinstall /home/usama/Documents/Droovia/node_modules/styled-components
> node ./scripts/postinstall.js || exit 0

Use styled-components at work? Consider supporting our development efforts at https://opencollective.com/styled-components

> react-toggle-component@2.0.11 postinstall /home/usama/Documents/Droovia/node_modules/react-toggle-component
> tsc -p tsconfig.json

sh: 1: tsc: not found
npm WARN server@1.0.0 No description
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.9 (node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.9: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})

npm ERR! code ELIFECYCLE
npm ERR! syscall spawn
npm ERR! file sh
npm ERR! errno ENOENT
npm ERR! react-toggle-component@2.0.11 postinstall: `tsc -p tsconfig.json`
npm ERR! spawn ENOENT
npm ERR! 
npm ERR! Failed at the react-toggle-component@2.0.11 postinstall script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/usama/.npm/_logs/2019-09-21T01_25_49_555Z-debug.log


@seyedasfar seyedasfar changed the title Can Can Install react-toggle-component "sh: 1: tsc: not found" Sep 21, 2019
@seyedasfar seyedasfar changed the title Can Install react-toggle-component "sh: 1: tsc: not found" Can't Install react-toggle-component "sh: 1: tsc: not found" Sep 21, 2019
@jean182
Copy link

jean182 commented Sep 23, 2019

Hey I had the same issue, I solved it installing typescript as a global package.

yarn global add typescript

@robincsamuel
Copy link

It'd be nice if this can be mentioned in the readme as a prerequisite.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants