Skip to content

Commit

Permalink
Switch to ESM imports (#91)
Browse files Browse the repository at this point in the history
Updates to use ESM imports now that Eleventy v3 supports it.

(Thanks to @paulrobertlloyd for the idea in
x-govuk/x-govuk.github.io#151)
  • Loading branch information
frankieroberto authored Dec 1, 2024
1 parent 8d77e11 commit de42d20
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
6 changes: 3 additions & 3 deletions eleventy.config.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
const govukEleventyPlugin = require('@x-govuk/govuk-eleventy-plugin')
const rssPlugin = require("@11ty/eleventy-plugin-rss");
import govukEleventyPlugin from '@x-govuk/govuk-eleventy-plugin'
import rssPlugin from "@11ty/eleventy-plugin-rss"

module.exports = function(eleventyConfig) {
export default function(eleventyConfig) {

eleventyConfig.addPlugin(rssPlugin);

Expand Down
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,6 @@
"@11ty/eleventy": "^3.0.0",
"@x-govuk/govuk-eleventy-plugin": "^6.7.0"
},
"private": true
"private": true,
"type": "module"
}

0 comments on commit de42d20

Please sign in to comment.