【问题标题】:Erro in npm run buildnpm 运行构建中的错误
【发布时间】:2022-11-02 11:32:35
【问题描述】:

我试图在我的 Svelte 项目中使用@vitejs/plugin-legacy,但是当我给出命令 npm run build 时,它给出了这个错误:

[vite-plugin-svelte-kit] ENOENT: no such file or directory, open 'C:\Users\pedro\OneDrive\Documentos\digital_lock\digital_lock\.svelte-kit/output/client//manifest.json'
error during build:
Error: ENOENT: no such file or directory, open 'C:\Users\pedro\OneDrive\Documentos\digital_lock\digital_lock\.svelte-kit/output/client//manifest.json'

我的 vite.config.ts:

import { sveltekit } from '@sveltejs/kit/vite';
import legacy from '@vitejs/plugin-legacy'

/** @type {import('vite').UserConfig} */
const config = {
    plugins: [
        sveltekit(),
        legacy({
            targets: ['defaults', 'not IE 11']
          })
    ],
    server: {
        fs: {
            allow: ['..']
        }
    },
};

export default config;

我正在尝试将我的应用程序配置为在较旧的浏览器版本中工作

【问题讨论】:

    标签: svelte vite npm-build


    【解决方案1】:

    发生与您相同的错误,这让我感到困惑。

    【讨论】:

      猜你喜欢
      • 2018-06-29
      • 1970-01-01
      • 2018-08-06
      • 2021-03-22
      • 2016-11-01
      • 2018-11-13
      • 2021-08-10
      • 2021-12-14
      • 2021-04-12
      相关资源
      最近更新 更多