Search code examples
decoratorivyangular9

Angular 9 - ERROR in In Ivy, decorator metadata must be inline


Angular 9 and ivy have only recently been published. But the migration is giving me a headache right now. Unfortunately the listed error is nowhere to be found and is not very meaningful. I ask for help!

compilation error


Solution

  • I had same problem and it was fixed by replacing

    @Injectable(({ providedIn: 'root' }))
    

    with

    @Injectable({ providedIn: 'root' })
    

    Main idea is that decorator should accept object !