diff --git a/netlify.toml b/netlify.toml index 182a663..29a66a8 100644 --- a/netlify.toml +++ b/netlify.toml @@ -1,3 +1,16 @@ [build] publish = "_site" command = "npm run build" + +[[plugins]] + package = "@netlify/plugin-lighthouse" + + # optional, fails build when a category is below a threshold + [plugins.inputs.thresholds] + performance = 1.0 + accessibility = 1.0 + best-practices = 1.0 + seo = 1.0 + + [plugins.inputs] + output_path = "reports/lighthouse/index.html" diff --git a/package.json b/package.json index 437ec71..2e3b7ef 100644 --- a/package.json +++ b/package.json @@ -37,6 +37,7 @@ "@11ty/eleventy-navigation": "^0.3.5", "@11ty/eleventy-plugin-rss": "^1.2.0", "@11ty/eleventy-plugin-syntaxhighlight": "^4.2.0", + "@netlify/plugin-lighthouse": "^4.0.6", "luxon": "^3.2.1", "markdown-it-anchor": "^8.6.6" }