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
Make absolute path for dlls relative #5055
Comments
Same problem. We have a several environments and want to put storybooks to each of them as a subfolder, but we can't because of that absolute path. Had tried to change |
Same problem here! |
I'm also affected by this. In my case, I'm publishing to GitHub Pages, which are always |
Same problem here |
+1, I'm affected by this as well |
For anyone else running across this, here's a build command that should fix this temporarily {
"scripts" : {
"build-storybook": "rm -rf storybook-static && build-storybook && sed -i -e 's/\\\/sb_dll/sb_dll/g' storybook-static/index.html"
}
} |
I'm going to fix this ASAP |
Boo-yah!! I just released https://github.com/storybooks/storybook/releases/tag/v5.0.0-alpha.1 containing PR #5238 that references this issue. Upgrade today to try it out! Because it's a pre-release you can find it on the |
Mind giving this a try and letting me know if it works for you? If so, I'll cherry-pick this back to @cmwhiting @mysticatea @alex996 @ozio @asychev @Chariyski @baohouse @benjablanko @gpincheiraa @Stevo14850 @unindented @liss-mouse @vio @Pluzu @lauriejones @yhuard @johnhunter @heavenshell @dkimura @dangerdespain @ndelangen |
Already. Can confirm that new path is relative: |
storybook DLL was not being loaded because of absolute path Fixed in storybookjs/storybook#5055 but not merged into their stable branch yet.
Whoopee!! I just released https://github.com/storybooks/storybook/releases/tag/v4.1.9 containing PR #5238 that references this issue. Upgrade today to try it out! |
This appears to resolve an issue in regards to absolute vs relative path for the dll javascript bundle: storybookjs/storybook#5055
This appears to resolve an issue in regards to absolute vs relative path for the dll javascript bundle: storybookjs/storybook#5055
This appears to resolve an issue in regards to absolute vs relative path for the dll javascript bundle: storybookjs/storybook#5055 brandingbrand-source-id: 90b5f838b4f335e0a059dd898ee1bc30a28aba6a
The dlls are loaded as
dlls: ['/sb_dll/storybook_ui_dll.js']
in@storybook/core/src/server/manager/manager-webpack.config.js
, but if you're serving static files outside of the root directory, this will fail. This should hopefully be something relative, likedlls: ['sb_dll/storybook_ui_dll.js']
ordlls: ['./sb_dll/storybook_ui_dll.js']
Ex: I have a node server stood up on
localhost:4000
, serving from./public
. I change my storybook output directory to./public/storybook
. The files are created, and loadinglocalhost:4000/storybook
serves the page, but requestslocalhost:4000/sb_dll/storybook_ui_dll.js
, which doesn't exist. With relative pathing, it would request aslocalhost:4000/storybook/sb_dll/storybook_ui_dll.js
, which would resolve correctly.The text was updated successfully, but these errors were encountered: