Closed GaryB432 closed 7 years ago
Looks like a duplicate of https://github.com/Microsoft/TypeScript/issues/12724
can you give typescript@2.2.0-dev.20161215
a try?
yeah that seems to work. thanks! I guess I'll wait for 2.2 to go to latest
before leaving ts-helpers
behind
We should be publishing 2.1.5 with he fix soon.
@mhegazy any clarity you can offer on "soon"?
We are targeting next week.
Hello,
I've installed TypeScript 2.1.5 Tools for Visual Studio as well as the npm package globally AND in my project, and I'm still getting red squiggly lines under code like this:
extends React.Component<{}, {}>
Tooltip error being this syntax requires an imported helper but module 'tslib' cannot be found.
Note that it doesn't prevent the project from being transpiled.
TSLib 1.5.0 is in my package.json dependencies section, and it's in _nodemodules. tsconfig has importHelpers = true.
Since it's Visual Studio related I tried to add this line (not documented but makes sense) in my .csproj:
<TypeScriptImportHelpers>True</TypeScriptImportHelpers>
I'm not supposed to import it explicitly, do I? Or maybe point to a definition file?
@Strato, this looks like a bug do you mind filing a new issue under https://github.com/Microsoft/TypeScript/issues
Following is my package.json
{
"name": "digital-labels",
"version": "0.0.0",
"scripts": {
"ng": "ng",
"start": "ng serve",
"build": "ng build",
"test": "ng test",
"lint": "ng lint",
"e2e": "ng e2e",
"compodoc": "compodoc -p src/tsconfig.app.json"
},
"private": true,
"dependencies": {
"@angular/animations": "^6.0.7",
"@angular/cdk": "^6.3.2",
"@angular/common": "^6.0.3",
"@angular/compiler": "^6.0.3",
"@angular/core": "^6.0.3",
"@angular/forms": "^6.0.3",
"@angular/http": "^6.0.3",
"@angular/material": "^6.3.2",
"@angular/platform-browser": "^6.0.3",
"@angular/platform-browser-dynamic": "^6.0.3",
"@angular/pwa": "^0.6.8",
"@angular/router": "^6.0.3",
"@angular/service-worker": "^6.0.3",
"@ng-idle/core": "^6.0.0-beta.3",
"angularx-social-login": "^1.2.0",
"core-js": "^2.5.4",
"hammerjs": "^2.0.8",
"hide-virtual-keyboard": "^1.0.1",
"ng2-avatar": "^2.3.1",
"ng2-search-filter": "^0.4.7",
"rxjs": "^6.0.0",
"tslib": "^1.9.3",
"zone.js": "^0.8.26"
},
"devDependencies": {
"@angular-devkit/build-angular": "~0.6.8",
"@angular/cli": "~6.0.8",
"@angular/compiler-cli": "^6.0.3",
"@angular/language-service": "^6.0.3",
"@compodoc/compodoc": "^1.1.3",
"@types/jasmine": "~2.8.6",
"@types/jasminewd2": "~2.0.3",
"@types/node": "~8.9.4",
"codelyzer": "~4.2.1",
"jasmine-core": "~2.99.1",
"jasmine-spec-reporter": "~4.2.1",
"karma": "~1.7.1",
"karma-chrome-launcher": "~2.2.0",
"karma-coverage-istanbul-reporter": "~2.0.0",
"karma-jasmine": "~1.1.1",
"karma-jasmine-html-reporter": "^0.2.2",
"protractor": "~5.3.0",
"ts-node": "~5.0.1",
"tslint": "~5.9.1",
"typescript": "~2.7.2"
},
"description": "This project was generated with [Angular CLI](https://github.com/angular/angular-cli)
version 6.0.8.",
"main": "index.js",
"repository": {
"type": "git",
"url": "git+https://rahul1406@bitbucket.org/morrisonsplc/esels-digital-labels-pwa.git"
},
"author": "",
"license": "ISC",
"homepage": "https://bitbucket.org/morrisonsplc/esels-digital-labels-pwa#readme"
}
Once i run 'ng test', i receive the following errors:
1) No captured browser, open http://localhost:9876/ 2) Uncaught Error: Cannot find module "tslib".
I deleted node_modules and ran 'npm install'. But this solution didn't work. What should i do? I can't run karma test runner and hence a blocker in my test driven development cycle. Please suggest me a solution!
try npm install --save tslib, thats what helped me out.
Hi guys. I'm getting this error when I run `node_modules/.bin/tsc' in the following folder.
error TS2354: This syntax requires an imported helper but module 'tslib' cannot be found.
The offending line (rxjs/Subscriber.d.ts(13,36) does indeed include an innocent looking
extend
keyword. Can you tell me what I'm doing wrong?src/main.ts
tsconfig.json
package.json
rxjs/Subscriber.d.ts(13)
I posted my question to stackoverflow but can't get any interest