Skip to content

Commit 766690d

Browse files
committedApr 21, 2024··
minor plugin fix
1 parent 38c4dc2 commit 766690d

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed
 

‎plugins/changelog.ts

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import fs from "fs";
22
import https from "https";
3-
import { Plugin } from "node_modules/vite/dist/node/index";
3+
import { Plugin } from "vite";
44

55
export interface Commit {
66
sha: string;
@@ -88,7 +88,7 @@ async function getChangelog(): Promise<string> {
8888
resp.on("end", () => {
8989
resolve(data);
9090
});
91-
}
91+
},
9292
)
9393
.on("error", (err) => {
9494
reject(err);
@@ -101,6 +101,7 @@ async function getChangelog(): Promise<string> {
101101

102102
export default function createPlugin(): Plugin {
103103
return {
104+
name: "Changelog",
104105
enforce: "pre",
105106
async transform(code) {
106107
if (code.includes("import.meta.CHANGELOG")) {

0 commit comments

Comments
 (0)
Please sign in to comment.