Skip to content

Commit

Permalink
♻️ Remove redundant exist-check
Browse files Browse the repository at this point in the history
  • Loading branch information
KenAJoh committed Dec 19, 2024
1 parent 9ce9b2b commit 03c7445
Showing 1 changed file with 5 additions and 7 deletions.
12 changes: 5 additions & 7 deletions @navikt/core/tokens/config/version-tag.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,9 @@ const version = packageJson.version;
for (const path of cssFilePaths) {
let cssContent = readFileSync(path, "utf8");

if (!cssContent.includes("--ax-version")) {
cssContent = cssContent.replace(
":root, :host {",
`:root, :host {\n --ax-version: "${version}";`,
);
writeFileSync(path, cssContent);
}
cssContent = cssContent.replace(
":root, :host {",
`:root, :host {\n --ax-version: "${version}";`,
);
writeFileSync(path, cssContent);
}

0 comments on commit 03c7445

Please sign in to comment.