3 Star 8 Fork 2

egege/mermaid

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
vite.config.ts 1.26 KB
一键复制 编辑 原始数据 按行查看 历史
Ashish Jain 提交于 2024-07-15 15:04 . fix: broken test, link style
import jison from './.vite/jisonPlugin.js';
import jsonSchemaPlugin from './.vite/jsonSchemaPlugin.js';
import typescript from '@rollup/plugin-typescript';
import { defaultExclude, defineConfig } from 'vitest/config';
import path from 'path';
export default defineConfig({
resolve: {
extensions: ['.js'],
alias: {
// Define your alias here
$root: path.resolve(__dirname, 'packages/mermaid/src'),
},
},
plugins: [
jison(),
jsonSchemaPlugin(), // handles .schema.yaml JSON Schema files
typescript({ compilerOptions: { declaration: false } }),
],
test: {
environment: 'jsdom',
globals: true,
// TODO: should we move this to a mermaid-core package?
setupFiles: ['packages/mermaid/src/tests/setup.ts'],
coverage: {
provider: 'v8',
reporter: ['text', 'json', 'html', 'lcov'],
reportsDirectory: './coverage/vitest',
exclude: [...defaultExclude, './tests/**', '**/__mocks__/**', '**/generated/'],
},
includeSource: ['packages/*/src/**/*.{js,ts}'],
},
build: {
/** If you set esmExternals to true, this plugins assumes that
all external dependencies are ES modules */
commonjsOptions: {
esmExternals: true,
},
},
define: {
'import.meta.vitest': 'undefined',
},
});
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/egege_gitee/mermaid.git
[email protected]:egege_gitee/mermaid.git
egege_gitee
mermaid
mermaid
develop

搜索帮助