You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Failed to load config from vite.config.js error when starting dev server.
I did see #59 but an error persists.
Reproduction
npm init vite@latest vite-svelte-test --template svelte
cd vite-svelte-test
npm install
npm run dev
Logs
failed to load config from /Users/sfm17/software/personal/vite-svelte-test/vite.config.js
error when starting dev server:
file:///Users/sfm17/software/personal/vite-svelte-test/node_modules/@sveltejs/vite-plugin-svelte/dist/index.js:800
import { diff_match_patch, DIFF_DELETE, DIFF_INSERT } from "diff-match-patch";
^^^^^^^^^^^
SyntaxError: The requested module 'diff-match-patch' is expected to be of type CommonJS, which does not support named exports. CommonJS modules can be imported by importing the default export.
For example:
import pkg from 'diff-match-patch';
const { diff_match_patch, DIFF_DELETE, DIFF_INSERT } = pkg;
at ModuleJob._instantiate (internal/modules/esm/module_job.js:97:21)
at async ModuleJob.run (internal/modules/esm/module_job.js:135:5)
at async Loader.import (internal/modules/esm/loader.js:178:24)
at async loadConfigFromFile (/Users/sfm17/software/personal/vite-svelte-test/node_modules/vite/dist/node/chunks/dep-11db14da.js:75342:31)
at async resolveConfig (/Users/sfm17/software/personal/vite-svelte-test/node_modules/vite/dist/node/chunks/dep-11db14da.js:74965:28)
at async createServer (/Users/sfm17/software/personal/vite-svelte-test/node_modules/vite/dist/node/chunks/dep-11db14da.js:73483:20)
at async CAC.<anonymous> (/Users/sfm17/software/personal/vite-svelte-test/node_modules/vite/dist/node/cli.js:13959:24)
I notice that you are using an outdated version of node 14 (14.4.0). Please update it and try again.
vite-plugin-svelte requires "node": "^12.20 || ^14.13.1 || >= 16"
If it still fails and you did any modification to the template after creating it, please provide a repository with them.
Describe the bug
Failed to load config from vite.config.js error when starting dev server.
I did see #59 but an error persists.
Reproduction
npm init vite@latest vite-svelte-test --template svelte cd vite-svelte-test npm install npm run dev
Logs
System Info
Severity
blocking all usage of vite-plugin-svelte
The text was updated successfully, but these errors were encountered: