
Security News
Deno 2.4 Brings Back deno bundle, Improves Dependency Management and Observability
Deno 2.4 brings back bundling, improves dependency updates and telemetry, and makes the runtime more practical for real-world JavaScript projects.
newsapi.js
is a TypeScript (and plain JS) library for newsapi.org.
Just run:
npm install newsapi.js -s
And some examples:
const news = require("newsapi.js");
// For TypeScript: import {NewsAPIClient} from "newsapi.js"
const sources = news.getSources()
.then(source => console.log(sources)) // Wouldn't do this if I were you
.catch((err) => console.error(err));
const topHeadlines = news.getTopHeadlines()
.then(headline => {
const articles = headline.articles;
console.log(articles[0].title);
});
Just create a PR! Testing information is below:
All the hard Mocha & TypeScript work is done for you. But you need to provide yourself a token from here: https://newsapi.org/account.
Once you have received a token, create a file at src/test/config/test.config.json
with the following content:
{
"token": "token here"
}
While replacing the string token here
with your token.
Then run the following:
$ npm install
and to test:
$ npm test
We abide by the MIT license.
FAQs
A TypeScript/JS wrapper for the News API newsapi.org
We found that newsapi.js demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Deno 2.4 brings back bundling, improves dependency updates and telemetry, and makes the runtime more practical for real-world JavaScript projects.
Security News
CVEForecast.org uses machine learning to project a record-breaking surge in vulnerability disclosures in 2025.
Security News
Browserslist-rs now uses static data to reduce binary size by over 1MB, improving memory use and performance for Rust-based frontend tools.