Skip to content
Discussion options

You must be logged in to vote

I've figured out a workaround for this by using eleventy's before hook. I may end up putting together a starter template that's more refined, but here is the gist of what my configuration looks like:

const { EleventyI18nPlugin } = require("@11ty/eleventy");
const fs = require('fs-extra');
const glob = require('glob');

module.exports = function(eleventyConfig) {
  // Add src/es/**/*.html to .gitignore since they are copies
  // Make sure eleventy still uses them in build
  eleventyConfig.setUseGitIgnore(false);
  eleventyConfig.addPlugin(EleventyI18nPlugin, {
    defaultLanguage: "en",
  });

  eleventyConfig.on('eleventy.before',
    async () => {
      // Find all templates from the "ma…

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by bkjohnson
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
1 participant