Skip to content

Commit

Permalink
fix: fix build by removing defineConfig
Browse files Browse the repository at this point in the history
Signed-off-by: Hung-Han (Henry) Chen <[email protected]>
  • Loading branch information
chenhunghan committed Jan 7, 2024
1 parent 47d4a72 commit 36bb0ee
Showing 1 changed file with 7 additions and 13 deletions.
20 changes: 7 additions & 13 deletions src/index.ts
Original file line number Diff line number Diff line change
@@ -1,15 +1,12 @@
import {
defineConfig,
type Logger,
type Plugin,
type ResolvedConfig,
} from "vite";
import { type Logger, type Plugin, type ResolvedConfig } from "vite";
import { $ } from "execa";
import fs from "fs-extra";
import path from "path";
import { load as jsTomlLoad } from "js-toml";

function vitePluginTrunk(vitePluginTruckConfig?: { debug?: boolean }): Plugin {
export function vitePluginTrunk(vitePluginTruckConfig?: {
debug?: boolean;
}): Plugin {
let config: ResolvedConfig;
let logger: Logger;
const name = "vite-plugin-trunk";
Expand Down Expand Up @@ -257,13 +254,10 @@ function vitePluginTrunk(vitePluginTruckConfig?: { debug?: boolean }): Plugin {
`${config.build.outDir}/${jsFile.name}`,
);
}
logger.info(`🦀 trunk successfully built wasm modules`, { timestamp: true });
logger.info(`🦀 trunk successfully built wasm modules`, {
timestamp: true,
});
}
},
};
}

// https://vitejs.dev/config/
export default defineConfig({
plugins: [vitePluginTrunk()],
});

0 comments on commit 36bb0ee

Please sign in to comment.