Histoire config object in Vite config breaks when using HstVue
t0byman opened this issue · comments
Describe the bug
On https://histoire.dev/guide/config.html it says The second option is to provide the Histoire config object directly in your Vite config file vite.config.{js,ts}.
but you can't do this when you use HstVue. You'll get this error:
✘ [ERROR] "@histoire/plugin-vue" resolved to an ESM file. ESM file cannot be loaded by `require`. See http://vitejs.dev/guide/troubleshooting.html#this-package-is-esm-only for more details. [plugin externalize-deps]
Reproduction
https://stackblitz.com/edit/histoire-vue3-starter-hw9lmd?file=vite.config.ts
System Info
Not possible in StackBlitz
Used Package Manager
npm
Validations
- Follow our Code of Conduct
- Read the Contributing Guidelines.
- Read the docs.
- Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.
- Check that this is a concrete bug. For Q&A open a GitHub Discussion.
- The provided reproduction is a minimal reproducible example of the bug.
Start a new pull request in StackBlitz Codeflow.