Skip to content
Discussion options

You must be logged in to vote

Alright - This was kind of silly, and definitely an artefact of the shenanigans I'm trying to pull.

This was the file:

config/vite.json

{
  "all": {
    "sourceCodeDir": "app/javascript",
    "watchAdditionalPaths": []
  },
  "development": {
    "host": "0.0.0.0",
    "autoBuild": true,
    "publicOutputDir": "vite-dev",
    "port": 6006 // <------------- HERE
  },
  "test": {
    "autoBuild": true,
    "publicOutputDir": "vite-test",
    "port": 3037
  }
}

By changing the Rails/Vite default there of 3036 to the Storybook 6006, Storybook can also function as the Rails vite dev server. Neat!

(And, when running vite dev on its own, everything works as expected)

Replies: 3 comments 1 reply

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
1 reply
@ellyssonmike
Comment options

Answer selected by rangerscience
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Help
Labels
None yet
2 participants