Security News
Node.js EOL Versions CVE Dubbed the "Worst CVE of the Year" by Security Experts
Critics call the Node.js EOL CVE a misuse of the system, sparking debate over CVE standards and the growing noise in vulnerability databases.
node-linkchecker
Advanced tools
Detect broken links and broken fragments
npm install node-linkchecker
.check(url[, options])
Find broken links and optionally broken fragments on a given url. Parameters:
url
: the url you want to checkoptions
: provide that parameter if you want to override the default options. See below for more detailsExample:
var nlc = require('./lib/node-linkchecker');
nlc.check("http://www.example.org/").then(function(result) {
if(result.brokenLinks.length > 0) {
console.log('the document contains broken links');
}
if(result.brokenFragments.length > 0) {
console.log('the document contains broken fragments');
}
});
###
var nlc = require('./lib/node-linkchecker')
, options = {
schemes: ["https:"],
userAgent: "W3C node linkchecker",
fragments: false
};
nlc.check("https://www.example.org/", options)
.then(function(result) {
// { brokenLinks: [], brokenFragments: [] }
}, function(err) {
console.log('rejection');
});
option | description | default |
---|---|---|
schemes | an array of schemes you want to check | ["http:", "https:"] |
userAgent | the user agent to be used for each request | node-linkchecker |
fragments | whether to look for broken fragments or not | true |
href
FAQs
Find broken links and broken fragments
The npm package node-linkchecker receives a total of 12 weekly downloads. As such, node-linkchecker popularity was classified as not popular.
We found that node-linkchecker demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 2 open source maintainers 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
Critics call the Node.js EOL CVE a misuse of the system, sparking debate over CVE standards and the growing noise in vulnerability databases.
Security News
cURL and Go security teams are publicly rejecting CVSS as flawed for assessing vulnerabilities and are calling for more accurate, context-aware approaches.
Security News
Bun 1.2 enhances its JavaScript runtime with 90% Node.js compatibility, built-in S3 and Postgres support, HTML Imports, and faster, cloud-first performance.