bzarras / newsapi

A promise-based node interface for NewsAPI
MIT License
144 stars 39 forks source link

Could not find a declarative file for module "newsapi" #43

Open GodsonAddy opened 1 year ago

GodsonAddy commented 1 year ago

I installed the newsapi npm package to us in my node. It works perfectly in my localhost but when I hover on the const newsAPI = require("newsapi , it says : module "c:/Users/Godson/OneDrive/Documents/GitHub/blog/node_modules/newsapi/dist/index" Could not find a declaration file for module 'newsapi'. 'c:/Users/Godson/OneDrive/Documents/GitHub/blog/node_modules/newsapi/dist/index.js' implicitly has an 'any' type. Try npm i --save-dev @types/newsapi if it exists or add a new declaration (.d.ts) file containing declare module 'newsapi'; and this affects my repo when I deploy to render, it also says Error: Cannot find module "newsapi.

My node version is v16.15.1

ErencanPelin commented 1 year ago

facing the same error now, i know its been ages but did you ever find a fix? 🤔

GodsonAddy commented 1 year ago

facing the same error now, i know its been ages but did you ever find a fix? 🤔

No please