| |
outDir: "build",
|
| |
rollupOptions: {
|
| |
output: {
|
| - |
manualChunks: {
|
| - |
markdown: [
|
| - |
"@radicle/gray-matter",
|
| - |
"dompurify",
|
| - |
"hast-util-to-dom",
|
| - |
"hast-util-to-html",
|
| - |
"katex",
|
| - |
"marked",
|
| - |
],
|
| - |
syntax: ["@wooorm/starry-night"],
|
| - |
grammarsTsx: [
|
| - |
"@wooorm/starry-night/source.ts",
|
| - |
"@wooorm/starry-night/source.tsx",
|
| - |
],
|
| - |
grammars: [
|
| - |
"@wooorm/starry-night/source.python",
|
| - |
"@wooorm/starry-night/source.js",
|
| - |
"@wooorm/starry-night/source.perl",
|
| - |
"@wooorm/starry-night/source.haskell",
|
| - |
"@wooorm/starry-night/source.ruby",
|
| - |
"@wooorm/starry-night/source.css",
|
| - |
"@wooorm/starry-night/source.solidity",
|
| - |
"@wooorm/starry-night/source.cs",
|
| - |
"@wooorm/starry-night/source.swift",
|
| - |
],
|
| - |
dom: ["svelte", "twemoji"],
|
| + |
manualChunks: id => {
|
| + |
if (id.includes("lodash")) {
|
| + |
return "lodash";
|
| + |
} else if (id.includes("katex")) {
|
| + |
return "katex";
|
| + |
} else if (id.includes("node_modules")) {
|
| + |
return "vendor";
|
| + |
} else if (id.includes("components")) {
|
| + |
return "components";
|
| + |
}
|
| |
},
|
| |
},
|
| |
},
|