How to import automapper-ts in Angular 9

Viewed 295

So I was updating a project from Angular 7 to Angular 9 and once I was done with the update the Automapper-ts is throwing error.

It was working perfectly fine with Angular 7. I am importing like this

import * as automapper from 'automapper-ts';

but now when I try to build it says

'automapper.d.ts' is not a module.

I have followed the exact steps mention on the Github page for Automapper-ts

I am kind of stuck now.

I am new to Angular so please bear with me if I am making a silly mistake :)

terminal output

1 Answers

SOLUTION: Just add this to the top of your file:

import 'automapper-ts';
Related