Skip to content

Commit ca62317

Browse files
committed
chore: read package.json using fs instead of import assertion
1 parent 378fbfb commit ca62317

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

rollup.config.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,11 @@ import path from "node:path";
33
import url from "node:url";
44
import typescript from "rollup-plugin-typescript2";
55
import dts from "rollup-plugin-dts";
6-
import pkg from "./package.json" assert { type: "json" };
76

87
const __filename = url.fileURLToPath(import.meta.url);
98
const __dirname = path.dirname(__filename);
109
const LICENSE = fs.readFileSync("LICENSE", { encoding: "utf-8" });
10+
const pkg = JSON.parse(fs.readFileSync("package.json", { encoding: "utf-8" }));
1111
const banner = [
1212
"/*!",
1313
...LICENSE.split("\n").map(o => ` * ${o}`),

0 commit comments

Comments
 (0)