DEV Community

Discussion on: Using Storybook with Quasar

Collapse
 
daemswibowo profile image
Dimas Wibowo

Hi thanks for the tutorial, it works perfectly!
But when im import quasar.variables.scss to preview.js it doesnt work :(
Can you help me ?

Thread Thread
 
hosseinghs profile image
Hossein Ghobadi Samani

I have the same issue, any updates?

Thread Thread
 
kavehkarami profile image
Kaveh Karami

I followed this approach:

First, I built my quasar app using npm run build.
Then, I moved the css file from the dist directory to the .storybook directory and renamed it to styles.css.
Finally, I imported it into the preview.ts file using import './styles.css'.

Additionally, I wrote a bash script to automate this process and run it before executing npm run storybook.

{
  "scripts": {
      "storybook": "sh ./run.sh && storybook dev -p 6006",
    }
}
Enter fullscreen mode Exit fullscreen mode