build/metalsmith/plugins/absolute-url.js
Function transform
has 26 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function transform($, file, fileName, options) {
const absolute = path.join(options.resolve, fileName);
if (options.canonical) {
const canonical = options.canonical + fileName;
const $canonical = $('<link rel="canonical" href="">').attr('href', canonical);
'new Buffer()' was deprecated since v6. Use 'Buffer.alloc()' or 'Buffer.from()' (use 'https://www.npmjs.com/package/safe-buffer' for '<4.5.0') instead. Open
Open
files[key].contents = new Buffer(page.html());
- Read upRead up
- Exclude checks
For more information visit Source: http://eslint.org/docs/rules/