Error TS1005: ';' expected. TypeScript Angular 6 For First Build error rxjs inside node_modules
I'm building my first Angular Application. I'm creating a new Angular application using this command ng new purchase-section
. But when I executing the application using ng serve -o
I got the following error.
ERROR in node_modules/rxjs/internal/types.d.ts(81,44): error TS1005:
';' expected. node_modules/rxjs/internal/types.d.ts(81,74): error
TS1005: ';' expected. node_modules/rxjs/internal/types.d.ts(81,77):
error TS1109: Expression expected.
I have inspected types.d.ts
as I know it is created by Angular.
I'm not able to understand the error. Note that after I got this error I deleted node_modules
and I installed using npm install
wished I got away still I got this error.
Here is my package.JSON
file:
{
"name": "purchase-section",
"version": "0.0.0",
"scripts": {
"ng": "ng",
"start": "ng serve",
"build": "ng build",
"test": "ng test",
"lint": "ng lint",
"e2e": "ng e2e"
},
"private": true,
"dependencies": {
"@angular/animations": "^6.0.3",
"@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/platform-browser": "^6.0.3",
"@angular/platform-browser-dynamic": "^6.0.3",
"@angular/router": "^6.0.3",
"core-js": "^2.5.4",
"rxjs": "^6.0.0",
"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",
"@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": "^4.0.0",
"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.4.2",
"ts-node": "~5.0.1",
"tslint": "~5.9.1",
"typescript": "~2.7.2"
}
}
angular typescript
New contributor
add a comment |
I'm building my first Angular Application. I'm creating a new Angular application using this command ng new purchase-section
. But when I executing the application using ng serve -o
I got the following error.
ERROR in node_modules/rxjs/internal/types.d.ts(81,44): error TS1005:
';' expected. node_modules/rxjs/internal/types.d.ts(81,74): error
TS1005: ';' expected. node_modules/rxjs/internal/types.d.ts(81,77):
error TS1109: Expression expected.
I have inspected types.d.ts
as I know it is created by Angular.
I'm not able to understand the error. Note that after I got this error I deleted node_modules
and I installed using npm install
wished I got away still I got this error.
Here is my package.JSON
file:
{
"name": "purchase-section",
"version": "0.0.0",
"scripts": {
"ng": "ng",
"start": "ng serve",
"build": "ng build",
"test": "ng test",
"lint": "ng lint",
"e2e": "ng e2e"
},
"private": true,
"dependencies": {
"@angular/animations": "^6.0.3",
"@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/platform-browser": "^6.0.3",
"@angular/platform-browser-dynamic": "^6.0.3",
"@angular/router": "^6.0.3",
"core-js": "^2.5.4",
"rxjs": "^6.0.0",
"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",
"@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": "^4.0.0",
"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.4.2",
"ts-node": "~5.0.1",
"tslint": "~5.9.1",
"typescript": "~2.7.2"
}
}
angular typescript
New contributor
Related issue on RxJS GitHub page: github.com/ReactiveX/rxjs/issues/4512
– martin
6 hours ago
Hey did you ever find a answer to this problem, I am having the same issue and none of the below answers solved anything. By the way I am using ng4(Angular 4).
– yfdgvf asdasdas
42 mins ago
add a comment |
I'm building my first Angular Application. I'm creating a new Angular application using this command ng new purchase-section
. But when I executing the application using ng serve -o
I got the following error.
ERROR in node_modules/rxjs/internal/types.d.ts(81,44): error TS1005:
';' expected. node_modules/rxjs/internal/types.d.ts(81,74): error
TS1005: ';' expected. node_modules/rxjs/internal/types.d.ts(81,77):
error TS1109: Expression expected.
I have inspected types.d.ts
as I know it is created by Angular.
I'm not able to understand the error. Note that after I got this error I deleted node_modules
and I installed using npm install
wished I got away still I got this error.
Here is my package.JSON
file:
{
"name": "purchase-section",
"version": "0.0.0",
"scripts": {
"ng": "ng",
"start": "ng serve",
"build": "ng build",
"test": "ng test",
"lint": "ng lint",
"e2e": "ng e2e"
},
"private": true,
"dependencies": {
"@angular/animations": "^6.0.3",
"@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/platform-browser": "^6.0.3",
"@angular/platform-browser-dynamic": "^6.0.3",
"@angular/router": "^6.0.3",
"core-js": "^2.5.4",
"rxjs": "^6.0.0",
"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",
"@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": "^4.0.0",
"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.4.2",
"ts-node": "~5.0.1",
"tslint": "~5.9.1",
"typescript": "~2.7.2"
}
}
angular typescript
New contributor
I'm building my first Angular Application. I'm creating a new Angular application using this command ng new purchase-section
. But when I executing the application using ng serve -o
I got the following error.
ERROR in node_modules/rxjs/internal/types.d.ts(81,44): error TS1005:
';' expected. node_modules/rxjs/internal/types.d.ts(81,74): error
TS1005: ';' expected. node_modules/rxjs/internal/types.d.ts(81,77):
error TS1109: Expression expected.
I have inspected types.d.ts
as I know it is created by Angular.
I'm not able to understand the error. Note that after I got this error I deleted node_modules
and I installed using npm install
wished I got away still I got this error.
Here is my package.JSON
file:
{
"name": "purchase-section",
"version": "0.0.0",
"scripts": {
"ng": "ng",
"start": "ng serve",
"build": "ng build",
"test": "ng test",
"lint": "ng lint",
"e2e": "ng e2e"
},
"private": true,
"dependencies": {
"@angular/animations": "^6.0.3",
"@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/platform-browser": "^6.0.3",
"@angular/platform-browser-dynamic": "^6.0.3",
"@angular/router": "^6.0.3",
"core-js": "^2.5.4",
"rxjs": "^6.0.0",
"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",
"@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": "^4.0.0",
"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.4.2",
"ts-node": "~5.0.1",
"tslint": "~5.9.1",
"typescript": "~2.7.2"
}
}
angular typescript
angular typescript
New contributor
New contributor
edited yesterday
double-beep
2,1382824
2,1382824
New contributor
asked yesterday
Rifat MurtuzaRifat Murtuza
11115
11115
New contributor
New contributor
Related issue on RxJS GitHub page: github.com/ReactiveX/rxjs/issues/4512
– martin
6 hours ago
Hey did you ever find a answer to this problem, I am having the same issue and none of the below answers solved anything. By the way I am using ng4(Angular 4).
– yfdgvf asdasdas
42 mins ago
add a comment |
Related issue on RxJS GitHub page: github.com/ReactiveX/rxjs/issues/4512
– martin
6 hours ago
Hey did you ever find a answer to this problem, I am having the same issue and none of the below answers solved anything. By the way I am using ng4(Angular 4).
– yfdgvf asdasdas
42 mins ago
Related issue on RxJS GitHub page: github.com/ReactiveX/rxjs/issues/4512
– martin
6 hours ago
Related issue on RxJS GitHub page: github.com/ReactiveX/rxjs/issues/4512
– martin
6 hours ago
Hey did you ever find a answer to this problem, I am having the same issue and none of the below answers solved anything. By the way I am using ng4(Angular 4).
– yfdgvf asdasdas
42 mins ago
Hey did you ever find a answer to this problem, I am having the same issue and none of the below answers solved anything. By the way I am using ng4(Angular 4).
– yfdgvf asdasdas
42 mins ago
add a comment |
11 Answers
11
active
oldest
votes
I had the same issue. I investigated that rxjs released a new version: 6.4.0
. And it broke the build. According to review, the minimum supported version of TypeScript is 2.8
. If you don't want to update TypeScript version, just change "rxjs": "^6.0.0", to "rxjs": "6.3.3"
in package.json
.
New contributor
i have same issue my "typescript": "~3.2.2" and "rxjs": "6.3.3" please tell me anyone how to solve this error?
– kalai
yesterday
just change "rxjs": "^6.0.0", to "rxjs": "6.3.3" in package.json and run command npm install again so it will update it in your project. Now It will work
– Nasreen Ustad
19 hours ago
add a comment |
Just remove ^
character from "rxjs": "^6.0.0"
from package.json
file and make it "rxjs": "6.0.0"
. It should work fine.
New contributor
1
I then had to delete mynode_modules
and runnpm i
again, but it worked. (Alternative :npm update
)
– Jeremy Thille
yesterday
That did it, life saver.
– RyanOC
8 hours ago
add a comment |
I was facing the same issue while developing an angular6 project. I spent more time finally it's working for me.
Here is the solution:
Open "package.json"2
rxjs
and "TypeScript" verstion like below screenshot
Change like the below screenshot:
Next go to your project folder and delete "node_modules" folder.
After deleting, next run
npm install
in your project folderFinally run
ng serve
. It should work (I tried 3 projects and confirmed).
This seems to work for me but do you know what the actual reason for this error is ? I mean until now it worked fine with the "^" symbol. Do you maybe have more details regarding what is causing this error ? Thanks
– Viocartman
yesterday
add a comment |
Seems like your Angular and/or rxjs version is not compatible with TypeScript.
Remove the ~
sign in the TypeScript version, add ^
instead. Then, install packages again.
Try running npm start
and ng build
prior to ng serve
.
did this but same error
– Rifat Murtuza
yesterday
Restart Visual Studio after this. What is your TS version now?
– Code_maniac
yesterday
this helped me. Thanks! (new version 2.9.2 worked perfectly)
– bakytn
12 hours ago
add a comment |
Just change the TypeScript dependency version to ^2.8
This is just a duplicate of this IMO.
– double-beep
16 hours ago
add a comment |
In your Package.json
file remove ^
symbol (caret) from "rxjs": "^6.0.0"
and add "rxjs": "6.0.0"
it will work fine.
This is just a duplicate answer of this one IMO. Before posting here, check the other answers.
– double-beep
16 hours ago
add a comment |
I have tried all the other answers. But I found issue. I had ts lint plugin installed which forced file to be ended without space. I removed it and it is working.
You can also remove the space going to that specific file.
add a comment |
These two changes what you want:
// in package.json:
"rxjs": "^6.2.2"
==> "rxjs": "latest"
"typescript": "2.7.2"
==> "typescript": "2.8"
where ==>
means to replace
add a comment |
You can update your npm
version to the latest, if it isn't, with:
npm update -g
this will update rxjs and the typescrip
– Hezy Ziv
yesterday
add a comment |
I changed the version for rxjs and typescript. My package.json has the following entries
"typescript": "^2.7.2"
"rxjs": "^6.3.3",
I also had to upgrade angular cli.
New contributor
add a comment |
Your package.json has following lines:
"rxjs": "^6.0.0",
"typescript": "~2.7.2"
This tells npm to install the following versions
rxjs: Latest version in version 6 series which is 6.4.0
typescript: Latest patched version in minor version 2.7 which is 2.7.2
Now RxJS module also installs the type definition files for TypeScript. The type definition file included in the rxjs module that got installed in your project is not compatible with typescript version installed in the same project.
So as a solution in your package.json file you can either bump up the version of Typescript to say 2.8 as
typescript: ^2.8.0
or bump down the version of ngrx to something like
ngrx: ~6.0.0
and
do a fresh npm install.
You can check the version number of the module installed by looking in following files:
node_modules/rxjs/package.json and
node_modules/typescript/package.json
add a comment |
Your Answer
StackExchange.ifUsing("editor", function () {
StackExchange.using("externalEditor", function () {
StackExchange.using("snippets", function () {
StackExchange.snippets.init();
});
});
}, "code-snippets");
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "1"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Rifat Murtuza is a new contributor. Be nice, and check out our Code of Conduct.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f54434333%2ferror-ts1005-expected-typescript-angular-6-for-first-build-error-rxjs-insi%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
11 Answers
11
active
oldest
votes
11 Answers
11
active
oldest
votes
active
oldest
votes
active
oldest
votes
I had the same issue. I investigated that rxjs released a new version: 6.4.0
. And it broke the build. According to review, the minimum supported version of TypeScript is 2.8
. If you don't want to update TypeScript version, just change "rxjs": "^6.0.0", to "rxjs": "6.3.3"
in package.json
.
New contributor
i have same issue my "typescript": "~3.2.2" and "rxjs": "6.3.3" please tell me anyone how to solve this error?
– kalai
yesterday
just change "rxjs": "^6.0.0", to "rxjs": "6.3.3" in package.json and run command npm install again so it will update it in your project. Now It will work
– Nasreen Ustad
19 hours ago
add a comment |
I had the same issue. I investigated that rxjs released a new version: 6.4.0
. And it broke the build. According to review, the minimum supported version of TypeScript is 2.8
. If you don't want to update TypeScript version, just change "rxjs": "^6.0.0", to "rxjs": "6.3.3"
in package.json
.
New contributor
i have same issue my "typescript": "~3.2.2" and "rxjs": "6.3.3" please tell me anyone how to solve this error?
– kalai
yesterday
just change "rxjs": "^6.0.0", to "rxjs": "6.3.3" in package.json and run command npm install again so it will update it in your project. Now It will work
– Nasreen Ustad
19 hours ago
add a comment |
I had the same issue. I investigated that rxjs released a new version: 6.4.0
. And it broke the build. According to review, the minimum supported version of TypeScript is 2.8
. If you don't want to update TypeScript version, just change "rxjs": "^6.0.0", to "rxjs": "6.3.3"
in package.json
.
New contributor
I had the same issue. I investigated that rxjs released a new version: 6.4.0
. And it broke the build. According to review, the minimum supported version of TypeScript is 2.8
. If you don't want to update TypeScript version, just change "rxjs": "^6.0.0", to "rxjs": "6.3.3"
in package.json
.
New contributor
edited yesterday
double-beep
2,1382824
2,1382824
New contributor
answered yesterday
Bolat KazybayevBolat Kazybayev
21114
21114
New contributor
New contributor
i have same issue my "typescript": "~3.2.2" and "rxjs": "6.3.3" please tell me anyone how to solve this error?
– kalai
yesterday
just change "rxjs": "^6.0.0", to "rxjs": "6.3.3" in package.json and run command npm install again so it will update it in your project. Now It will work
– Nasreen Ustad
19 hours ago
add a comment |
i have same issue my "typescript": "~3.2.2" and "rxjs": "6.3.3" please tell me anyone how to solve this error?
– kalai
yesterday
just change "rxjs": "^6.0.0", to "rxjs": "6.3.3" in package.json and run command npm install again so it will update it in your project. Now It will work
– Nasreen Ustad
19 hours ago
i have same issue my "typescript": "~3.2.2" and "rxjs": "6.3.3" please tell me anyone how to solve this error?
– kalai
yesterday
i have same issue my "typescript": "~3.2.2" and "rxjs": "6.3.3" please tell me anyone how to solve this error?
– kalai
yesterday
just change "rxjs": "^6.0.0", to "rxjs": "6.3.3" in package.json and run command npm install again so it will update it in your project. Now It will work
– Nasreen Ustad
19 hours ago
just change "rxjs": "^6.0.0", to "rxjs": "6.3.3" in package.json and run command npm install again so it will update it in your project. Now It will work
– Nasreen Ustad
19 hours ago
add a comment |
Just remove ^
character from "rxjs": "^6.0.0"
from package.json
file and make it "rxjs": "6.0.0"
. It should work fine.
New contributor
1
I then had to delete mynode_modules
and runnpm i
again, but it worked. (Alternative :npm update
)
– Jeremy Thille
yesterday
That did it, life saver.
– RyanOC
8 hours ago
add a comment |
Just remove ^
character from "rxjs": "^6.0.0"
from package.json
file and make it "rxjs": "6.0.0"
. It should work fine.
New contributor
1
I then had to delete mynode_modules
and runnpm i
again, but it worked. (Alternative :npm update
)
– Jeremy Thille
yesterday
That did it, life saver.
– RyanOC
8 hours ago
add a comment |
Just remove ^
character from "rxjs": "^6.0.0"
from package.json
file and make it "rxjs": "6.0.0"
. It should work fine.
New contributor
Just remove ^
character from "rxjs": "^6.0.0"
from package.json
file and make it "rxjs": "6.0.0"
. It should work fine.
New contributor
edited yesterday
double-beep
2,1382824
2,1382824
New contributor
answered yesterday
AdityaAditya
1293
1293
New contributor
New contributor
1
I then had to delete mynode_modules
and runnpm i
again, but it worked. (Alternative :npm update
)
– Jeremy Thille
yesterday
That did it, life saver.
– RyanOC
8 hours ago
add a comment |
1
I then had to delete mynode_modules
and runnpm i
again, but it worked. (Alternative :npm update
)
– Jeremy Thille
yesterday
That did it, life saver.
– RyanOC
8 hours ago
1
1
I then had to delete my
node_modules
and run npm i
again, but it worked. (Alternative : npm update
)– Jeremy Thille
yesterday
I then had to delete my
node_modules
and run npm i
again, but it worked. (Alternative : npm update
)– Jeremy Thille
yesterday
That did it, life saver.
– RyanOC
8 hours ago
That did it, life saver.
– RyanOC
8 hours ago
add a comment |
I was facing the same issue while developing an angular6 project. I spent more time finally it's working for me.
Here is the solution:
Open "package.json"2
rxjs
and "TypeScript" verstion like below screenshot
Change like the below screenshot:
Next go to your project folder and delete "node_modules" folder.
After deleting, next run
npm install
in your project folderFinally run
ng serve
. It should work (I tried 3 projects and confirmed).
This seems to work for me but do you know what the actual reason for this error is ? I mean until now it worked fine with the "^" symbol. Do you maybe have more details regarding what is causing this error ? Thanks
– Viocartman
yesterday
add a comment |
I was facing the same issue while developing an angular6 project. I spent more time finally it's working for me.
Here is the solution:
Open "package.json"2
rxjs
and "TypeScript" verstion like below screenshot
Change like the below screenshot:
Next go to your project folder and delete "node_modules" folder.
After deleting, next run
npm install
in your project folderFinally run
ng serve
. It should work (I tried 3 projects and confirmed).
This seems to work for me but do you know what the actual reason for this error is ? I mean until now it worked fine with the "^" symbol. Do you maybe have more details regarding what is causing this error ? Thanks
– Viocartman
yesterday
add a comment |
I was facing the same issue while developing an angular6 project. I spent more time finally it's working for me.
Here is the solution:
Open "package.json"2
rxjs
and "TypeScript" verstion like below screenshot
Change like the below screenshot:
Next go to your project folder and delete "node_modules" folder.
After deleting, next run
npm install
in your project folderFinally run
ng serve
. It should work (I tried 3 projects and confirmed).
I was facing the same issue while developing an angular6 project. I spent more time finally it's working for me.
Here is the solution:
Open "package.json"2
rxjs
and "TypeScript" verstion like below screenshot
Change like the below screenshot:
Next go to your project folder and delete "node_modules" folder.
After deleting, next run
npm install
in your project folderFinally run
ng serve
. It should work (I tried 3 projects and confirmed).
edited yesterday
double-beep
2,1382824
2,1382824
answered yesterday
imjayabalimjayabal
829
829
This seems to work for me but do you know what the actual reason for this error is ? I mean until now it worked fine with the "^" symbol. Do you maybe have more details regarding what is causing this error ? Thanks
– Viocartman
yesterday
add a comment |
This seems to work for me but do you know what the actual reason for this error is ? I mean until now it worked fine with the "^" symbol. Do you maybe have more details regarding what is causing this error ? Thanks
– Viocartman
yesterday
This seems to work for me but do you know what the actual reason for this error is ? I mean until now it worked fine with the "^" symbol. Do you maybe have more details regarding what is causing this error ? Thanks
– Viocartman
yesterday
This seems to work for me but do you know what the actual reason for this error is ? I mean until now it worked fine with the "^" symbol. Do you maybe have more details regarding what is causing this error ? Thanks
– Viocartman
yesterday
add a comment |
Seems like your Angular and/or rxjs version is not compatible with TypeScript.
Remove the ~
sign in the TypeScript version, add ^
instead. Then, install packages again.
Try running npm start
and ng build
prior to ng serve
.
did this but same error
– Rifat Murtuza
yesterday
Restart Visual Studio after this. What is your TS version now?
– Code_maniac
yesterday
this helped me. Thanks! (new version 2.9.2 worked perfectly)
– bakytn
12 hours ago
add a comment |
Seems like your Angular and/or rxjs version is not compatible with TypeScript.
Remove the ~
sign in the TypeScript version, add ^
instead. Then, install packages again.
Try running npm start
and ng build
prior to ng serve
.
did this but same error
– Rifat Murtuza
yesterday
Restart Visual Studio after this. What is your TS version now?
– Code_maniac
yesterday
this helped me. Thanks! (new version 2.9.2 worked perfectly)
– bakytn
12 hours ago
add a comment |
Seems like your Angular and/or rxjs version is not compatible with TypeScript.
Remove the ~
sign in the TypeScript version, add ^
instead. Then, install packages again.
Try running npm start
and ng build
prior to ng serve
.
Seems like your Angular and/or rxjs version is not compatible with TypeScript.
Remove the ~
sign in the TypeScript version, add ^
instead. Then, install packages again.
Try running npm start
and ng build
prior to ng serve
.
edited yesterday
double-beep
2,1382824
2,1382824
answered yesterday
Code_maniacCode_maniac
1651211
1651211
did this but same error
– Rifat Murtuza
yesterday
Restart Visual Studio after this. What is your TS version now?
– Code_maniac
yesterday
this helped me. Thanks! (new version 2.9.2 worked perfectly)
– bakytn
12 hours ago
add a comment |
did this but same error
– Rifat Murtuza
yesterday
Restart Visual Studio after this. What is your TS version now?
– Code_maniac
yesterday
this helped me. Thanks! (new version 2.9.2 worked perfectly)
– bakytn
12 hours ago
did this but same error
– Rifat Murtuza
yesterday
did this but same error
– Rifat Murtuza
yesterday
Restart Visual Studio after this. What is your TS version now?
– Code_maniac
yesterday
Restart Visual Studio after this. What is your TS version now?
– Code_maniac
yesterday
this helped me. Thanks! (new version 2.9.2 worked perfectly)
– bakytn
12 hours ago
this helped me. Thanks! (new version 2.9.2 worked perfectly)
– bakytn
12 hours ago
add a comment |
Just change the TypeScript dependency version to ^2.8
This is just a duplicate of this IMO.
– double-beep
16 hours ago
add a comment |
Just change the TypeScript dependency version to ^2.8
This is just a duplicate of this IMO.
– double-beep
16 hours ago
add a comment |
Just change the TypeScript dependency version to ^2.8
Just change the TypeScript dependency version to ^2.8
edited 16 hours ago
double-beep
2,1382824
2,1382824
answered yesterday
Sanju VargheseSanju Varghese
30913
30913
This is just a duplicate of this IMO.
– double-beep
16 hours ago
add a comment |
This is just a duplicate of this IMO.
– double-beep
16 hours ago
This is just a duplicate of this IMO.
– double-beep
16 hours ago
This is just a duplicate of this IMO.
– double-beep
16 hours ago
add a comment |
In your Package.json
file remove ^
symbol (caret) from "rxjs": "^6.0.0"
and add "rxjs": "6.0.0"
it will work fine.
This is just a duplicate answer of this one IMO. Before posting here, check the other answers.
– double-beep
16 hours ago
add a comment |
In your Package.json
file remove ^
symbol (caret) from "rxjs": "^6.0.0"
and add "rxjs": "6.0.0"
it will work fine.
This is just a duplicate answer of this one IMO. Before posting here, check the other answers.
– double-beep
16 hours ago
add a comment |
In your Package.json
file remove ^
symbol (caret) from "rxjs": "^6.0.0"
and add "rxjs": "6.0.0"
it will work fine.
In your Package.json
file remove ^
symbol (caret) from "rxjs": "^6.0.0"
and add "rxjs": "6.0.0"
it will work fine.
edited 16 hours ago
double-beep
2,1382824
2,1382824
answered 17 hours ago
Sagar JadhavSagar Jadhav
52927
52927
This is just a duplicate answer of this one IMO. Before posting here, check the other answers.
– double-beep
16 hours ago
add a comment |
This is just a duplicate answer of this one IMO. Before posting here, check the other answers.
– double-beep
16 hours ago
This is just a duplicate answer of this one IMO. Before posting here, check the other answers.
– double-beep
16 hours ago
This is just a duplicate answer of this one IMO. Before posting here, check the other answers.
– double-beep
16 hours ago
add a comment |
I have tried all the other answers. But I found issue. I had ts lint plugin installed which forced file to be ended without space. I removed it and it is working.
You can also remove the space going to that specific file.
add a comment |
I have tried all the other answers. But I found issue. I had ts lint plugin installed which forced file to be ended without space. I removed it and it is working.
You can also remove the space going to that specific file.
add a comment |
I have tried all the other answers. But I found issue. I had ts lint plugin installed which forced file to be ended without space. I removed it and it is working.
You can also remove the space going to that specific file.
I have tried all the other answers. But I found issue. I had ts lint plugin installed which forced file to be ended without space. I removed it and it is working.
You can also remove the space going to that specific file.
edited yesterday
double-beep
2,1382824
2,1382824
answered yesterday
pranav-devpranav-dev
331
331
add a comment |
add a comment |
These two changes what you want:
// in package.json:
"rxjs": "^6.2.2"
==> "rxjs": "latest"
"typescript": "2.7.2"
==> "typescript": "2.8"
where ==>
means to replace
add a comment |
These two changes what you want:
// in package.json:
"rxjs": "^6.2.2"
==> "rxjs": "latest"
"typescript": "2.7.2"
==> "typescript": "2.8"
where ==>
means to replace
add a comment |
These two changes what you want:
// in package.json:
"rxjs": "^6.2.2"
==> "rxjs": "latest"
"typescript": "2.7.2"
==> "typescript": "2.8"
where ==>
means to replace
These two changes what you want:
// in package.json:
"rxjs": "^6.2.2"
==> "rxjs": "latest"
"typescript": "2.7.2"
==> "typescript": "2.8"
where ==>
means to replace
edited yesterday
double-beep
2,1382824
2,1382824
answered yesterday
Ali BahramiAli Bahrami
123212
123212
add a comment |
add a comment |
You can update your npm
version to the latest, if it isn't, with:
npm update -g
this will update rxjs and the typescrip
– Hezy Ziv
yesterday
add a comment |
You can update your npm
version to the latest, if it isn't, with:
npm update -g
this will update rxjs and the typescrip
– Hezy Ziv
yesterday
add a comment |
You can update your npm
version to the latest, if it isn't, with:
npm update -g
You can update your npm
version to the latest, if it isn't, with:
npm update -g
edited yesterday
double-beep
2,1382824
2,1382824
answered yesterday
Hezy ZivHezy Ziv
211
211
this will update rxjs and the typescrip
– Hezy Ziv
yesterday
add a comment |
this will update rxjs and the typescrip
– Hezy Ziv
yesterday
this will update rxjs and the typescrip
– Hezy Ziv
yesterday
this will update rxjs and the typescrip
– Hezy Ziv
yesterday
add a comment |
I changed the version for rxjs and typescript. My package.json has the following entries
"typescript": "^2.7.2"
"rxjs": "^6.3.3",
I also had to upgrade angular cli.
New contributor
add a comment |
I changed the version for rxjs and typescript. My package.json has the following entries
"typescript": "^2.7.2"
"rxjs": "^6.3.3",
I also had to upgrade angular cli.
New contributor
add a comment |
I changed the version for rxjs and typescript. My package.json has the following entries
"typescript": "^2.7.2"
"rxjs": "^6.3.3",
I also had to upgrade angular cli.
New contributor
I changed the version for rxjs and typescript. My package.json has the following entries
"typescript": "^2.7.2"
"rxjs": "^6.3.3",
I also had to upgrade angular cli.
New contributor
New contributor
answered 7 hours ago
sthayamkerysthayamkery
1
1
New contributor
New contributor
add a comment |
add a comment |
Your package.json has following lines:
"rxjs": "^6.0.0",
"typescript": "~2.7.2"
This tells npm to install the following versions
rxjs: Latest version in version 6 series which is 6.4.0
typescript: Latest patched version in minor version 2.7 which is 2.7.2
Now RxJS module also installs the type definition files for TypeScript. The type definition file included in the rxjs module that got installed in your project is not compatible with typescript version installed in the same project.
So as a solution in your package.json file you can either bump up the version of Typescript to say 2.8 as
typescript: ^2.8.0
or bump down the version of ngrx to something like
ngrx: ~6.0.0
and
do a fresh npm install.
You can check the version number of the module installed by looking in following files:
node_modules/rxjs/package.json and
node_modules/typescript/package.json
add a comment |
Your package.json has following lines:
"rxjs": "^6.0.0",
"typescript": "~2.7.2"
This tells npm to install the following versions
rxjs: Latest version in version 6 series which is 6.4.0
typescript: Latest patched version in minor version 2.7 which is 2.7.2
Now RxJS module also installs the type definition files for TypeScript. The type definition file included in the rxjs module that got installed in your project is not compatible with typescript version installed in the same project.
So as a solution in your package.json file you can either bump up the version of Typescript to say 2.8 as
typescript: ^2.8.0
or bump down the version of ngrx to something like
ngrx: ~6.0.0
and
do a fresh npm install.
You can check the version number of the module installed by looking in following files:
node_modules/rxjs/package.json and
node_modules/typescript/package.json
add a comment |
Your package.json has following lines:
"rxjs": "^6.0.0",
"typescript": "~2.7.2"
This tells npm to install the following versions
rxjs: Latest version in version 6 series which is 6.4.0
typescript: Latest patched version in minor version 2.7 which is 2.7.2
Now RxJS module also installs the type definition files for TypeScript. The type definition file included in the rxjs module that got installed in your project is not compatible with typescript version installed in the same project.
So as a solution in your package.json file you can either bump up the version of Typescript to say 2.8 as
typescript: ^2.8.0
or bump down the version of ngrx to something like
ngrx: ~6.0.0
and
do a fresh npm install.
You can check the version number of the module installed by looking in following files:
node_modules/rxjs/package.json and
node_modules/typescript/package.json
Your package.json has following lines:
"rxjs": "^6.0.0",
"typescript": "~2.7.2"
This tells npm to install the following versions
rxjs: Latest version in version 6 series which is 6.4.0
typescript: Latest patched version in minor version 2.7 which is 2.7.2
Now RxJS module also installs the type definition files for TypeScript. The type definition file included in the rxjs module that got installed in your project is not compatible with typescript version installed in the same project.
So as a solution in your package.json file you can either bump up the version of Typescript to say 2.8 as
typescript: ^2.8.0
or bump down the version of ngrx to something like
ngrx: ~6.0.0
and
do a fresh npm install.
You can check the version number of the module installed by looking in following files:
node_modules/rxjs/package.json and
node_modules/typescript/package.json
answered 1 hour ago
PraymPraym
9941213
9941213
add a comment |
add a comment |
Rifat Murtuza is a new contributor. Be nice, and check out our Code of Conduct.
Rifat Murtuza is a new contributor. Be nice, and check out our Code of Conduct.
Rifat Murtuza is a new contributor. Be nice, and check out our Code of Conduct.
Rifat Murtuza is a new contributor. Be nice, and check out our Code of Conduct.
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f54434333%2ferror-ts1005-expected-typescript-angular-6-for-first-build-error-rxjs-insi%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Related issue on RxJS GitHub page: github.com/ReactiveX/rxjs/issues/4512
– martin
6 hours ago
Hey did you ever find a answer to this problem, I am having the same issue and none of the below answers solved anything. By the way I am using ng4(Angular 4).
– yfdgvf asdasdas
42 mins ago