Skip to content

Commit

Permalink
Use import attribute
Browse files Browse the repository at this point in the history
Signed-off-by: Sora Morimoto <sora@morimoto.io>
  • Loading branch information
smorimoto committed Dec 7, 2024
1 parent 552f53e commit 16641d9
Show file tree
Hide file tree
Showing 8 changed files with 121 additions and 119 deletions.
15 changes: 8 additions & 7 deletions de/de.11tydata.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
import { createRequire } from "node:module";

const require = createRequire(import.meta.url);
import intro from "./intro.json" with { type: "json" };
import proposals from "./proposals.json" with { type: "json" };
import site from "./site.json" with { type: "json" };
import stage3 from "./stage3.json" with { type: "json" };

export default {
intro: require("./intro.json"),
proposals: require("./proposals.json"),
site: require("./site.json"),
stage3: require("./stage3.json"),
intro: intro,
proposals: proposals,
site: site,
stage3: stage3,
locale: "de",
lang: "de",
};
15 changes: 8 additions & 7 deletions en/en.11tydata.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
import { createRequire } from "node:module";

const require = createRequire(import.meta.url);
import intro from "./intro.json" with { type: "json" };
import proposals from "./proposals.json" with { type: "json" };
import site from "./site.json" with { type: "json" };
import stage3 from "./stage3.json" with { type: "json" };

export default {
intro: require("./intro.json"),
proposals: require("./proposals.json"),
site: require("./site.json"),
stage3: require("./stage3.json"),
intro: intro,
proposals: proposals,
site: site,
stage3: stage3,
locale: "en",
lang: "en",
};
15 changes: 8 additions & 7 deletions fr/fr.11tydata.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
import { createRequire } from "node:module";

const require = createRequire(import.meta.url);
import intro from "./intro.json" with { type: "json" };
import proposals from "./proposals.json" with { type: "json" };
import site from "./site.json" with { type: "json" };
import stage3 from "./stage3.json" with { type: "json" };

export default {
intro: require("./intro.json"),
proposals: require("./proposals.json"),
site: require("./site.json"),
stage3: require("./stage3.json"),
intro: intro,
proposals: proposals,
site: site,
stage3: stage3,
locale: "fr",
lang: "fr",
};
15 changes: 8 additions & 7 deletions ja/ja.11tydata.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
import { createRequire } from "node:module";

const require = createRequire(import.meta.url);
import intro from "./intro.json" with { type: "json" };
import proposals from "./proposals.json" with { type: "json" };
import site from "./site.json" with { type: "json" };
import stage3 from "./stage3.json" with { type: "json" };

export default {
intro: require("./intro.json"),
proposals: require("./proposals.json"),
site: require("./site.json"),
stage3: require("./stage3.json"),
intro: intro,
proposals: proposals,
site: site,
stage3: stage3,
locale: "ja",
lang: "ja",
};
135 changes: 65 additions & 70 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

15 changes: 8 additions & 7 deletions ru/ru.11tydata.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
import { createRequire } from "node:module";

const require = createRequire(import.meta.url);
import intro from "./intro.json" with { type: "json" };
import proposals from "./proposals.json" with { type: "json" };
import site from "./site.json" with { type: "json" };
import stage3 from "./stage3.json" with { type: "json" };

export default {
intro: require("./intro.json"),
proposals: require("./proposals.json"),
site: require("./site.json"),
stage3: require("./stage3.json"),
intro: intro,
proposals: proposals,
site: site,
stage3: stage3,
locale: "ru",
lang: "ru",
};
15 changes: 8 additions & 7 deletions uk/uk.11tydata.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
import { createRequire } from "node:module";

const require = createRequire(import.meta.url);
import intro from "./intro.json" with { type: "json" };
import proposals from "./proposals.json" with { type: "json" };
import site from "./site.json" with { type: "json" };
import stage3 from "./stage3.json" with { type: "json" };

export default {
intro: require("./intro.json"),
proposals: require("./proposals.json"),
site: require("./site.json"),
stage3: require("./stage3.json"),
intro: intro,
proposals: proposals,
site: site,
stage3: stage3,
locale: "ua",
lang: "ua",
};
15 changes: 8 additions & 7 deletions zh-Hans/zh-Hans.11tydata.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
import { createRequire } from "node:module";

const require = createRequire(import.meta.url);
import intro from "./intro.json" with { type: "json" };
import proposals from "./proposals.json" with { type: "json" };
import site from "./site.json" with { type: "json" };
import stage3 from "./stage3.json" with { type: "json" };

export default {
intro: require("./intro.json"),
proposals: require("./proposals.json"),
site: require("./site.json"),
stage3: require("./stage3.json"),
intro: intro,
proposals: proposals,
site: site,
stage3: stage3,
locale: "zh-Hans",
lang: "zh-Hans",
};

0 comments on commit 16641d9

Please sign in to comment.