diff --git a/.eslintrc.js b/.eslintrc.js index 3273456..9d1ad45 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -1,13 +1,9 @@ module.exports = { env: { - es6: true, + es2020: true, node: true }, extends: "eslint:recommended", - parserOptions: { - sourceType: "module", - ecmaVersion: 2017 - }, rules: { indent: ["error", 2], "linebreak-style": ["error", "unix"], diff --git a/src/image-attrs-to-posthtml-node.js b/src/image-attrs-to-posthtml-node.js index 159b1c0..5d41f60 100644 --- a/src/image-attrs-to-posthtml-node.js +++ b/src/image-attrs-to-posthtml-node.js @@ -35,7 +35,7 @@ async function imageAttributesToPosthtmlNode(attributes, instanceOptions, global } if(!globalPluginOptions) { - throw new Error("Missing global defaults for `@11ty/eleventy-img`: did you call addPlugin?") + throw new Error("Missing global defaults for `@11ty/eleventy-img`: did you call addPlugin?"); } if(!instanceOptions) { @@ -64,7 +64,7 @@ async function imageAttributesToPosthtmlNode(attributes, instanceOptions, global // You bet we throw an error on missing alt in `imageAttributes` (alt="" works okay) let obj = await eleventyImage.generateObject(metadata, imageAttributes); return convertToPosthtmlNode(obj); -}; +} function cleanTag(node) { // Delete all prefixed attributes @@ -88,4 +88,4 @@ module.exports = { cleanTag, isIgnored, getOutputDirectory, -} +};