crisbeto / angular-svg-round-progressbar

Angular module that uses SVG to create a circular progressbar
https://crisbeto.github.io/angular-svg-round-progressbar/
MIT License
741 stars 174 forks source link

cant compile with angular 8/ivy "Injectable is not defined" #193

Closed JohanMouritsen closed 3 years ago

JohanMouritsen commented 5 years ago
Injectable is not defined
    at round-progress.service.js:84
    at Object../node_modules/angular-svg-round-progressbar/__ivy_ngcc__/dist/round-progress.service.js (round-progress.service.js:92)
    at __webpack_require__ (bootstrap:79)
    at Object../node_modules/angular-svg-round-progressbar/__ivy_ngcc__/dist/round-progress.component.js (round-progress.component.js:23)
    at __webpack_require__ (bootstrap:79)
    at Object../node_modules/angular-svg-round-progressbar/__ivy_ngcc__/dist/index.js (index.js:3)
    at __webpack_require__ (bootstrap:79)
    at Module../src/app/modules/widget/widget.module.ts (templates.module.ts:91)
    at __webpack_require__ (bootstrap:79)
    at Module../src/app/app-routing.module.ts (auth.guard.ts:7)

i am using these angular versions:

"@angular-devkit/build-angular": "^0.803.4",
    "@angular-devkit/core": "^7.3.9",
    "@angular/animations": "^8.2.6",
    "@angular/cdk": "^7.3.7",
    "@angular/common": "^8.2.6",
    "@angular/compiler": "^8.2.6",
    "@angular/core": "^8.2.6",
    "@angular/forms": "^8.2.6",
    "@angular/material": "^7.3.7",
    "@angular/platform-browser": "^8.2.6",
    "@angular/platform-browser-dynamic": "^8.2.6",
    "@angular/router": "^8.2.6",

and this version of round-progressbar: "angular-svg-round-progressbar": "^3.0.1",

the compiler will compile successfully and then get stuck with the above error. turning off ivy fixes the issue

crisbeto commented 5 years ago

Thanks for the report. It's probably due to the custom build script I have going on. I have it on my list to switch to ng-packagr at some point.

crisbeto commented 3 years ago

As of version 5.0.1 the project is using the standard Angular Package Format which should resolve this issue.