question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

ERROR in Symbol Toast declared

See original GitHub issue

Toastr 13.0.0 has an issue with ng10x compiler

ERROR in Symbol Toast declared in …/node_modules/ngx-toastr/toastr/toast.component.d.ts is not exported from ngx-toastr/toastr/toastr.module (import into …/src/app/app.component.ts)

Project deps version: "dependencies": { "@angular/animations": "~10.0.9", "@angular/cdk": "^10.1.3", "@angular/common": "~10.0.9", "@angular/compiler": "~10.0.9", "@angular/core": "~10.0.9", "@angular/forms": "~10.0.9", "@angular/material": "^10.1.3", "@angular/platform-browser": "~10.0.9", "@angular/platform-browser-dynamic": "~10.0.9", "@angular/router": "~10.0.9", "@ngx-translate/core": "^13.0.0", "@ngx-translate/http-loader": "^6.0.0", "angular-svg-icon": "^10.0.0", "ng5-slider": "^1.2.4", "ngx-mask": "^10.0.1", "ngx-toastr": "13.0.0", "rxjs": "~6.5.5", "tslib": "^2.0.0", "zone.js": "~0.10.3" }

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:6 (1 by maintainers)

github_iconTop GitHub Comments

4reactions
Chris380commented, Oct 8, 2020

I had the same issue. In my case the auto import by VS Code import { ToastrModule } from 'ngx-toastr/toastr/toastr.module'; caused the issue. Just changed it to import { ToastrModule } from 'ngx-toastr';.

0reactions
karanrane96commented, Oct 11, 2020

@Chris380 has given the solution. VS Code auto imports to import { ToastrModule } from ‘ngx-toastr/toastr/toastr.module’; Just change it to import { ToastrModule } from ‘ngx-toastr’; and you’re good to go.

Read more comments on GitHub >

github_iconTop Results From Across the Web

node_modules/ngx-toastr/toastr/toast-noanimation.component ...
ERROR in node_modules/@angular/animations/browser/browser.d.ts(135,9): error TS1086: An accessor cannot be declared in an ambient context.
Read more >
ngx-toastr - Bountysource
Everything is working as expected so it seems but i get this "Error". ERROR in node_modules/ngx-toastr/toastr/toastr.module.d.ts:5:53 - error TS-996005: ...
Read more >
Problems with Toast show() (Example) | Treehouse Community
There are several errors: Cannot resolve symbol makeText; Unexpected token; Unknown class "LENGTH_SHORT"; Missing method body, or declare ...
Read more >
Identifier has already been declared Error in JavaScript
The "Identifier has already been declared error" occurs when a variable with the same name has been declared multiple times in the same...
Read more >
ReferenceError: can't access lexical declaration 'X' before ...
At this point foo has not been initialized with a value, so accessing the variable throws a reference error. function test() { //...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found