Revision bb5edf1a1db9ae42efcf44195f4fc40e52d63ca0 authored by Ron Buckton on 09 January 2023, 21:12:56 UTC, committed by Ron Buckton on 09 January 2023, 21:12:56 UTC
1 parent f326cbf
.eslintplugin.js
const fs = require("fs");
const path = require("path");
const rulesDir = path.join(__dirname, "scripts", "eslint", "rules");
const ext = ".cjs";
const ruleFiles = fs.readdirSync(rulesDir).filter((p) => p.endsWith(ext));
module.exports = {
rules: Object.fromEntries(ruleFiles.map((p) => {
return [p.slice(0, -ext.length), require(path.join(rulesDir, p))];
})),
}
Computing file changes ...