Skip to content

Commit d3090ec

Browse files
committed
fix: another attempt to fix the ESM issue.
1 parent 2e77715 commit d3090ec

16 files changed

+38
-22
lines changed

.eleventy.js renamed to .eleventy.cjs

Lines changed: 31 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,36 @@
11
require("dotenv").config();
22

3-
const typescript = require("./src/engines/typescript/sample");
4-
const typescriptJSX = require("./src/engines/typescript/sample-jsx");
5-
const sass = require("./src/engines/sass");
6-
const stripRegionTags = require("./src/transforms/strip-region-tags");
7-
const stripLicenseHeaders = require("./src/transforms/strip-license-headers");
8-
const yourAPIKey = require("./src/transforms/your-api-key");
9-
const format = require("./src/transforms/format");
10-
const minify = require("./src/transforms/minify");
11-
const skypack = require("./src/transforms/skypack");
12-
const fs = require("fs");
13-
const path = require("path");
14-
const vite = require("vite");
15-
const chalk = require("chalk");
16-
const prettier = require("prettier");
17-
18-
module.exports = function (eleventyConfig) {
3+
// const typescript = require("./src/engines/typescript/sample");
4+
// const typescriptJSX = require("./src/engines/typescript/sample-jsx");
5+
// const sass = require("./src/engines/sass");
6+
// const stripRegionTags = require("./src/transforms/strip-region-tags");
7+
// const stripLicenseHeaders = require("./src/transforms/strip-license-headers");
8+
// const yourAPIKey = require("./src/transforms/your-api-key");
9+
// const format = require("./src/transforms/format");
10+
// const minify = require("./src/transforms/minify");
11+
// const skypack = require("./src/transforms/skypack");
12+
// const fs = require("fs");
13+
// const path = require("path");
14+
// const vite = require("vite");
15+
// const chalk = require("chalk");
16+
// const prettier = require("prettier");
17+
18+
const { typescript } = await ".src/engines/typescript/sample";
19+
const { typescriptJSX } = await "./src/engines/typescript/sample-jsx";
20+
const { sass } = await "./src/engines/sass";
21+
const { stripRegionTags } = await "./src/transforms/strip-region-tags";
22+
const { stripLicenseHeaders } = await "./src/transforms/strip-license-headers";
23+
const { yourAPIKey } = await "./src/transforms/your-api-key";
24+
const { format } = await "./src/transforms/format";
25+
const { minify } = await "./src/transforms/minify";
26+
const { skypack } = await "./src/transforms/skypack";
27+
const { fs } = await "fs";
28+
const { path } = await "path";
29+
const { vite } = await "vite";
30+
const { chalk } = await "chalk";
31+
const { prettier } = await "prettier";
32+
33+
export default function (eleventyConfig) {
1934
eleventyConfig.addWatchTarget("./shared/**/*");
2035
eleventyConfig.addWatchTarget(".env*");
2136

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
"name": "@googlemaps/js-samples",
33
"description": "Samples for Google Maps JavaScript",
44
"version": "2.1.4",
5+
"type": "module",
56
"keywords": [
67
"google",
78
"javascript",

playwright.config.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { PlaywrightTestConfig, devices } from "@playwright/test";
1+
import type { PlaywrightTestConfig, /* devices */ } from "@playwright/test";
22
import { test, expect, Expect } from "@playwright/test";
33
import fs from "fs";
44
import path from "path";
@@ -26,12 +26,12 @@ const config: PlaywrightTestConfig = {
2626
port: 8080,
2727
},
2828
updateSnapshots: "none",
29-
projects: [
29+
/* projects: [
3030
{
3131
name: "chromium",
3232
use: { ...devices["Desktop Chrome"] },
3333
},
34-
],
34+
], */
3535
reporter: process.env.CI ? "github" : "list",
3636
};
3737

File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 commit comments

Comments
 (0)