build(#10336): normalize path for Windows

This commit is contained in:
Acid Chicken (硫酸鶏) 2023-04-01 18:35:03 +09:00
parent 88981e9d5b
commit 0f334f900c
No known key found for this signature in database
GPG Key ID: 3E87B98A3F6BAB99
1 changed files with 3 additions and 3 deletions

View File

@ -1,6 +1,6 @@
import { resolve } from 'node:path'; import { resolve } from 'node:path';
import type { StorybookConfig } from '@storybook/vue3-vite'; import type { StorybookConfig } from '@storybook/vue3-vite';
import { mergeConfig } from 'vite'; import { mergeConfig, normalizePath } from 'vite';
import { viteStaticCopy } from 'vite-plugin-static-copy'; import { viteStaticCopy } from 'vite-plugin-static-copy';
const config = { const config = {
stories: ['../src/**/*.mdx', '../src/**/*.stories.@(js|jsx|ts|tsx)'], stories: ['../src/**/*.mdx', '../src/**/*.stories.@(js|jsx|ts|tsx)'],
@ -27,11 +27,11 @@ const config = {
viteStaticCopy({ viteStaticCopy({
targets: [ targets: [
{ {
src: resolve(__dirname, '../node_modules/@tabler/icons-webfont/*.css'), src: normalizePath(resolve(__dirname, '../node_modules/@tabler/icons-webfont/*.css')),
dest: 'node_modules/@tabler/icons-webfont', dest: 'node_modules/@tabler/icons-webfont',
}, },
{ {
src: resolve(__dirname, '../node_modules/@tabler/icons-webfont/fonts/*.{eot,ttf,woff,woff2}'), src: normalizePath(resolve(__dirname, '../node_modules/@tabler/icons-webfont/fonts/*.{eot,ttf,woff,woff2}')),
dest: 'node_modules/@tabler/icons-webfont/fonts', dest: 'node_modules/@tabler/icons-webfont/fonts',
}, },
], ],