mirror of
https://github.com/lucide-icons/lucide.git
synced 2025-12-16 16:57:44 +01:00
37 lines
911 B
TypeScript
37 lines
911 B
TypeScript
import copy from 'rollup-plugin-copy';
|
|
import replace from '@rollup/plugin-replace';
|
|
|
|
export default defineNitroConfig({
|
|
compatibilityDate: '2025-07-30',
|
|
preset: 'vercel_edge',
|
|
srcDir: '.vitepress',
|
|
routeRules: {
|
|
'/api/**': { cors: false },
|
|
},
|
|
rollupConfig: {
|
|
external: ['@resvg/resvg-wasm/index_bg.wasm', './index_bg.wasm?module'],
|
|
plugins: [
|
|
copy({
|
|
targets: [
|
|
{
|
|
src: './node_modules/@resvg/resvg-wasm/index_bg.wasm',
|
|
dest: './.vercel/output/functions/__nitro.func',
|
|
},
|
|
],
|
|
}),
|
|
replace({
|
|
include: ['./**/*.ts'],
|
|
'/* WASM_IMPORT */': 'import resvg_wasm from "./index_bg.wasm?module";',
|
|
delimiters: ['', ''],
|
|
preventAssignment: false,
|
|
}),
|
|
],
|
|
},
|
|
esbuild: {
|
|
options: {
|
|
jsxFactory: 'React.createElement',
|
|
jsxFragment: 'React.Fragment',
|
|
},
|
|
},
|
|
});
|