
Security News
Next.js Patches Critical Middleware Vulnerability (CVE-2025-29927)
Next.js has patched a critical vulnerability (CVE-2025-29927) that allowed attackers to bypass middleware-based authorization checks in self-hosted apps.
seo-recommender
Advanced tools
Parse HTML and provide suggestions on SEO. Powered by cheerio.
npm install seo-recommender
There are 5 pre-defined rule groups, used when specifying white list
There 3 rule types according to pre-defined rule groups, used when adding more rules
Provide a list of objects for adding custom rules.
Must be called before calling API run()
.
E.g. Check if <meta name="robots" />
exists or not
var rcmndr = new SEORecommender();
rcmndr.addRules([{
ruleType: RULE_TYPES.TAG_WITHOUT_TAG_WITH_ATTR_AND_VALUE,
tag: 'head',
conditions: {
tag: 'meta',
attr: 'name',
value: 'robots',
},
userDefinedConditions: null,
desc: 'This HTML does not have %s tag',
}]);
Start parsing and recommending.
Provide an options
object.
E.g. run with options:
var rcmndr = new SEORecommender();
rcmndr.run({
inType: INPUT_TYPE.FILE,
inPath: 'test.html',
outType: OUTPUT_TYPE.CONSOLE,
});
Check exmpale
for more information.
const fs = require('fs');
const {
SEORecommender,
INPUT_TYPE,
OUTPUT_TYPE,
PREDEFINED_RULE_GROUPS,
RULE_TYPES,
} = require('seo-recommender');
function inputFileOutputConsole() {
var rcmndr = new SEORecommender();
rcmndr.run({
inType: INPUT_TYPE.FILE,
inPath: 'test.html',
outType: OUTPUT_TYPE.CONSOLE,
});
}
function inputStreamOutputFile() {
var rcmndr = new SEORecommender();
var inStream = fs.createReadStream('test.html');
rcmndr.run({
inType: INPUT_TYPE.STREAM,
inStream: inStream,
outType: OUTPUT_TYPE.FILE,
outPath: 'output',
});
}
function inputStreamOutputStream() {
var rcmndr = new SEORecommender();
var inStream = fs.createReadStream('test.html');
rcmndr.run({
inType: INPUT_TYPE.STREAM,
inStream: inStream,
outType: OUTPUT_TYPE.STREAM,
callback: (writable) => {
console.log('writable =', writable);
},
});
}
function addRules() {
var rcmndr = new SEORecommender();
rcmndr.addRules([{
ruleType: RULE_TYPES.TAG_WITHOUT_TAG_WITH_ATTR_AND_VALUE,
tag: 'head',
conditions: {
tag: 'meta',
attr: 'name',
value: 'robots',
},
userDefinedConditions: null,
desc: 'This HTML does not have %s tag',
}]);
rcmndr.run({
inType: INPUT_TYPE.FILE,
inPath: 'test.html',
outType: OUTPUT_TYPE.CONSOLE,
});
}
function addRulesWhiteList() {
var rcmndr = new SEORecommender();
rcmndr.run({
rulesWhiteList: [PREDEFINED_RULE_GROUPS.IMG_WITHOUT_ALT],
inType: INPUT_TYPE.FILE,
inPath: 'test.html',
outType: OUTPUT_TYPE.CONSOLE,
});
}
inputFileOutputConsole();
//inputStreamOutputFile();
//inputStreamOutputStream();
//addRules();
//addRulesWhiteList();
FAQs
A SEO recommender for HTML files
The npm package seo-recommender receives a total of 0 weekly downloads. As such, seo-recommender popularity was classified as not popular.
We found that seo-recommender 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
Next.js has patched a critical vulnerability (CVE-2025-29927) that allowed attackers to bypass middleware-based authorization checks in self-hosted apps.
Security News
A survey of 500 cybersecurity pros reveals high pay isn't enough—lack of growth and flexibility is driving attrition and risking organizational security.
Product
Socket, the leader in open source security, is now available on Google Cloud Marketplace for simplified procurement and enhanced protection against supply chain attacks.