Skip to content

Commit

Permalink
chore: update vite config
Browse files Browse the repository at this point in the history
  • Loading branch information
qmhc committed Apr 11, 2023
1 parent 35490f4 commit 36f3d53
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 11 deletions.
25 changes: 15 additions & 10 deletions docs/.vitepress/config.ts
Original file line number Diff line number Diff line change
@@ -1,18 +1,27 @@
import { resolve } from 'node:path'
import { defineConfig } from 'vitepress'
import autoprefixer from 'autoprefixer'

export default defineConfig({
vite: {
logLevel: 'error',
logLevel: process.env.NODE_ENV === 'production' ? 'error' : undefined,
resolve: {
alias: {
'grid-layout-plus': resolve(__dirname, '../../src')
}
},
css: {
postcss: {
plugins: [autoprefixer]
}
},
server: {
fs: {
allow: ['..']
}
}
},
head: [
['link', { rel: 'icon', type: 'image/svg+xml', href: '/grid-layout-plus.svg' }]
],
head: [['link', { rel: 'icon', type: 'image/svg+xml', href: '/grid-layout-plus.svg' }]],
title: 'Grid Layout Plus',
lastUpdated: true,
themeConfig: {
Expand Down Expand Up @@ -63,9 +72,7 @@ export default defineConfig({
pattern: 'https://github.com/qmhc/grid-layout-plus/edit/main/docs/en/:path',
text: 'Edit this page on GitHub'
},
socialLinks: [
{ icon: 'github', link: 'https://github.com/qmhc/grid-layout-plus' }
],
socialLinks: [{ icon: 'github', link: 'https://github.com/qmhc/grid-layout-plus' }],
footer: {
message: 'Released under the MIT License.',
copyright: 'Copyright © 2023-present qmhc'
Expand Down Expand Up @@ -115,9 +122,7 @@ export default defineConfig({
pattern: 'https://github.com/qmhc/grid-layout-plus/edit/main/docs/:path',
text: '在 GitHub 上编辑此页'
},
socialLinks: [
{ icon: 'github', link: 'https://github.com/qmhc/grid-layout-plus' }
],
socialLinks: [{ icon: 'github', link: 'https://github.com/qmhc/grid-layout-plus' }],
docFooter: {
prev: '上一页',
next: '下一页'
Expand Down
5 changes: 4 additions & 1 deletion vitest.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,10 @@ export default defineConfig({
reporter: ['text'],
extension: ['ts', 'tsx', 'vue']
},
testTimeout: 10000
testTimeout: 10000,
deps: {
inline: [/@interactjs\//]
}
},
plugins: [vue(), vueJsx()]
})

0 comments on commit 36f3d53

Please sign in to comment.