histoire
histoire copied to clipboard
↗️ Auto "open browser" option
Clear and concise description of the problem
I want an option that will automatically open up the browser window when starting dev server or preview
I typically use --open in my package.json scripts but when trying to use this with Histoire it did not work.
Suggested solution
i.e.
"scripts": {
"story:dev": "histoire dev --port 6006 --open",
"story:build": "histoire build",
"story:preview": "histoire preview --port 6006 --open"
},
Alternative
No response
Additional context
No response
Validations
- [X] Follow our Code of Conduct
- [X] Read the Contributing Guidelines.
- [X] Read the docs.
- [X] Check that there isn't already an issue that requests the same feature to avoid creating a duplicate.
:laughing: , right after i submitted feature request i figured out how to do it.
Vite can do this easily from within the vite.config.js file
export default defineConfig({
server: {
open: '/'
}
})
https://vitejs.dev/config/server-options.html
you may or may not want to reimplement this functionality for histoire so i'll leave open for now
you may or may not want to reimplement this functionality for histoire so i'll leave open for now
Or document it on the histoire config page :)