Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Nuxt + Histoire doesn't work #244

Closed
6 tasks done
Bobakanoosh opened this issue Aug 15, 2022 · 1 comment
Closed
6 tasks done

Nuxt + Histoire doesn't work #244

Bobakanoosh opened this issue Aug 15, 2022 · 1 comment
Assignees
Labels
bug Something isn't working

Comments

@Bobakanoosh
Copy link

Describe the bug

  • I have made a fresh nuxt project on stackblitz (and locally via Nuxt's "getting started" instructions)
  • I then installed histoire while following the getting started for nuxt
  • I then created a basic Button.vue and Button.story.vue, and got the following errors in console when clicking on the story:
    image

For used package manager - I use pnpm locally but the reproduction stackblitz uses npm

Reproduction

https://stackblitz.com/edit/nuxt-starter-j2ib4c

System Info

System:
    OS: Windows 10 10.0.19043
    CPU: (24) x64 AMD Ryzen 9 5900X 12-Core Processor
    Memory: 15.30 GB / 31.94 GB
  Binaries:
    Node: 16.15.0 - C:\Program Files\nodejs\node.EXE
    Yarn: 1.22.17 - ~\AppData\Roaming\npm\yarn.CMD
    npm: 8.1.0 - C:\Program Files\nodejs\npm.CMD
  Browsers:
    Edge: Spartan (44.19041.1266.0), Chromium (104.0.1293.54)
    Internet Explorer: 11.0.19041.1566

Used Package Manager

pnpm

Validations

@Bobakanoosh Bobakanoosh added the to triage This issue needs to be triaged label Aug 15, 2022
@Lyokolux
Copy link
Contributor

Lyokolux commented Aug 16, 2022

I get the same issue. I updated from Histoire 8.2 to latest 10.2 with Nuxt RC 8.

During the build:

Unexpected token (Note that you need plugins to import files that are not JavaScript)
file: /$histoire-generated-global-setup-resolved:9:13
 7:                 }
 8:               }
 9:             },export async function setupVue3 (payload) {
                 ^
10:               for (const setup of setupList) {
11:                 if (setup?.setupVue3) {
file:<project_path>/node_modules/vite/node_modules/rollup/dist/es/shared/rollup.js:1858
        base = Object.assign(new Error(base.message), base);

In dev im Browser after the first load on click on a story:

Uncaught (in promise) SyntaxError: expected expression, got ',' [$histoire-generated-global-setup-resolved:9:13](<BASE_URL>/$histoire-generated-global-setup-resolved)

@Akryum Akryum added bug Something isn't working and removed to triage This issue needs to be triaged labels Aug 16, 2022
@Akryum Akryum self-assigned this Aug 16, 2022
@Akryum Akryum closed this as completed in ca080ad Aug 16, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants