histoire-dev / histoire-dev/histoire
Vue Error: Unhandled error during execution of scheduler flush (SvelteKit + Histoire + FakerJS)
- Dominant language
- TypeScript
- Stars
- 3.6k
- Forks
- 212
- PR merge metrics
- No merged PRs in 30d
Description
### Describe the bug
When importing FakerJS inside a Histoire story, a Vue warning and a Faker error are printed to the console, and the story no longer works. I originally opened [this issue](https://github.com/vuejs/core/issues/9946) in the Vue project and they told me that I should move it here.
### Reproduction
https://github.com/zachstence/histoire-faker-repro
Reproduction steps are in the README
### System Info
```shell
System:
OS: Linux 5.15 Ubuntu 22.04.3 LTS 22.04.3 LTS (Jammy Jellyfish)
CPU: (8) x64 AMD Ryzen 5 5600X 6-Core Processor
Memory: 20.97 GB / 23.47 GB
Container: Yes
Shell: 3.6.1 - /bin/fish
Binaries:
Node: 18.17.0 - ~/.local/share/nvm/v18.17.0/bin/node
npm: 9.6.7 - ~/.local/share/nvm/v18.17.0/bin/npm
bun: 1.0.11 - ~/.bun/bin/bun
Browsers:
Chrome: 120.0.6099.109
npmPackages:
@histoire/plugin-svelte: ^0.17.6 => 0.17.6
histoire: ^0.17.6 => 0.17.6
vite: ^4.4.2 => 4.5.1
```
### Used Package Manager
npm
### Validations
- [X] Follow our [Code of Conduct](https://github.com/histoire-dev/histoire/blob/main/CODE_OF_CONDUCT.md)
- [X] Read the [Contributing Guidelines](https://github.com/histoire-dev/histoire/blob/main/CONTRIBUTING.md).
- [X] Read the [docs](https://histoire.dev/guide/).
- [X] Check that there isn't [already an issue](https://github.com/histoire-dev/histoire/issues) that reports the same bug to avoid creating a duplicate.
- [X] Check that this is a concrete bug. For Q&A open a [GitHub Discussion](https://github.com/histoire-dev/histoire/discussions).
- [X] The provided reproduction is a [minimal reproducible example](https://stackoverflow.com/help/minimal-reproducible-example) of the bug.
Contributor guide
Research direction
Start with the reproduction repository linked in the issue and follow its README steps using the reported Histoire, Vite, and FakerJS setup. Reproduce the Vue warning and Faker error, then verify that the Histoire story works without those console errors.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, typescript, vite
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100