I am trying to import a JavaScript library called Akarata. I have followed the suggestions from the internet, such as:
import * as akarata from 'akarata/dist';
or
import * as akarata from 'akarata';
However, I am still encountering an error:
Try npm install @types/akarata if it exists or add a new declaration (.d.ts) file containing declare module 'akarata';
I have tried these solutions but nothing seems to work.
What's strange is that when I first type ng serve
(as I'm using Angular), the error appears. But after making some changes to my project and saving them, the error persists even though my project works fine and the library functions correctly.
Does anyone know why this is happening?