arkon / ng-inline-svg

[Inactive] Angular directive for inserting an SVG file inline within an element.
https://echeung.me/ng-inline-svg/
MIT License
210 stars 88 forks source link

Weird output and error after transpilation #125

Closed KonradLinkowski closed 4 years ago

KonradLinkowski commented 4 years ago
inline-svg.service.js:56 Uncaught TypeError: i0.ɵɵdefineInjectable is not a function
    at inline-svg.service.js:56
    at Object../node_modules/ng-inline-svg/lib/inline-svg.service.js (inline-svg.service.js:64)
    at __webpack_require__ (bootstrap:78)
    at Object../node_modules/ng-inline-svg/lib/inline-svg.component.js (inline-svg.component.js:14)
    at __webpack_require__ (bootstrap:78)
    at Object../node_modules/ng-inline-svg/lib/inline-svg.directive.js (inline-svg.directive.js:17)
    at __webpack_require__ (bootstrap:78)
    at Object../node_modules/ng-inline-svg/lib/index.js (index.js:5)
    at __webpack_require__ (bootstrap:78)
    at Module../src/app/app.module.ts (app.component.ts:9)
EhhChris commented 4 years ago

We ran into this issue as well on Angular 7 with the latest version 8.6.1, reverting to 8.6.0 fixed it.

damiencuvillier commented 4 years ago

Same here. Rollback to 8.6.0 works. Upgrade to 9.2 not.

Any stable solution ?

Ketec commented 4 years ago

The same issue - it does not seem to work with ivy.

Chiangmg84 commented 4 years ago

Currently on Angular 7. Not sure if there is a later version that works as well but I'm using an older version for now until this gets resolved.

npm install ng-inline-svg@8.6.0 --save-exact

arkon commented 4 years ago

I've released v8.6.2 and v9.2.1 which are the same as the previous versions but vend both commonjs and esmodule versions. Can you try those?

midasdev711 commented 3 years ago

Hi I am using angular 6 and same issue occurred. npm install ng-inline-svg@8.6.0 --save-exact I tried above solution but didn't work. Is there anyone who solved this issue on angular 6 before?