Skip to content

Commit

Permalink
[autofix.ci] apply automated fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
autofix-ci[bot] authored Nov 24, 2024
1 parent a2c047d commit 7391090
Showing 1 changed file with 19 additions and 18 deletions.
37 changes: 19 additions & 18 deletions packages/benchmarks/letters/gen.ts
Original file line number Diff line number Diff line change
Expand Up @@ -309,24 +309,25 @@ export const KanjiLetterComponent${
if (lib === "next-yak") {
const compiled =
"// @ts-nocheck\n" +
swc.transformSync(fileContent, {
filename: "/foo/index.tsx",
jsc: {
experimental: {
plugins: [[require.resolve("yak-swc"), { basePath: "/foo/" }]],
},
target: "es2022",
loose: false,
minify: {
compress: false,
mangle: false,
},
preserveAllComments: true,
},
minify: false,
isModule: true,
}).code
// Remove __styleYak import
swc
.transformSync(fileContent, {
filename: "/foo/index.tsx",
jsc: {
experimental: {
plugins: [[require.resolve("yak-swc"), { basePath: "/foo/" }]],
},
target: "es2022",
loose: false,
minify: {
compress: false,
mangle: false,
},
preserveAllComments: true,
},
minify: false,
isModule: true,
})
.code// Remove __styleYak import
.replace(/import[^;\n]+yak.module.css";/, "")
// Replace __styleYak usage to a string
.replace(/__styleYak.(\w+)/g, `"$1"`);
Expand Down

0 comments on commit 7391090

Please sign in to comment.