npm run lint fails
npm run lint fails on new project
admin1@PC-131:/home1/lamppp/htdocs/testCharts/charts-nethues$ npm run lint
> [email protected] lint /home1/lamppp/htdocs/testCharts/charts-nethues
> tslint --type-check --project tsconfig.json src/**/*.ts
/home1/lamppp/htdocs/testCharts/charts-nethues/node_modules/tslint/lib/runner.js:92
throw new Error(messages.join("\n"));
^
Error: Error at playground/index.ts:9:31: Cannot find module 'charts-nethues'.
Error at src/sample.component.spec.ts:7:1: Cannot find name 'describe'.
Error at src/sample.component.spec.ts:14:3: Cannot find name 'beforeEach'.
Error at src/sample.component.spec.ts:28:3: Cannot find name 'it'.
Error at src/sample.component.spec.ts:29:5: Cannot find name 'expect'.
at Runner.run (/home1/lamppp/htdocs/testCharts/charts-nethues/node_modules/tslint/lib/runner.js:92:27)
at Object.<anonymous> (/home1/lamppp/htdocs/testCharts/charts-nethues/node_modules/tslint/lib/tslint-cli.js:139:6)
at Module._compile (module.js:570:32)
at Object.Module._extensions..js (module.js:579:10)
at Module.load (module.js:487:32)
at tryModuleLoad (module.js:446:12)
at Function.Module._load (module.js:438:3)
at Module.require (module.js:497:17)
at require (internal/module.js:20:19)
at Object.<anonymous> (/home1/lamppp/htdocs/testCharts/charts-nethues/node_modules/tslint/bin/tslint:3:1)
npm ERR! Linux 4.4.0-93-generic
npm ERR! argv "/usr/local/bin/node" "/usr/local/bin/npm" "run" "lint"
npm ERR! node v6.8.1
npm ERR! npm v3.10.8
npm ERR! code ELIFECYCLE
npm ERR! [email protected] lint: `tslint --type-check --project tsconfig.json src/**/*.ts`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] lint script 'tslint --type-check --project tsconfig.json src/**/*.ts'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the charts-nethues package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! tslint --type-check --project tsconfig.json src/**/*.ts
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs charts-nethues
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls charts-nethues
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR! /home1/lamppp/htdocs/testCharts/charts-nethues/npm-debug.log
To get rid of the Cannot find name * errors, add "jasmine" to the array of types in /tsconfig.json. The error in the playground is related to #206, but that can be temporarily fixed by updating the import in /playground/index.ts to import { SampleModule } from '../src';.
import { SampleModule } from '../src';. is just a hack to pass the lint. The playground won't work with it
Same here. Freshly new (installed today) cant find my library module.
npm run test failling with same message
Cant move forward.
Any update? I did like this generator but I am unable to use it. Not even the hello world tutorial completes.
I have followed the exact scenarios from the docs.
Same, followed exactly as the docs. Ran
yo angular2-library then
npm run build
and it fails with Cannot find module '<project name>'
If instead of importing from '../src' like @IckleChris said if you do '../dist' it works with playground!