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

WebPack - Make public path dynamic #1441

Open
jamestalton opened this issue Jan 10, 2024 · 0 comments
Open

WebPack - Make public path dynamic #1441

jamestalton opened this issue Jan 10, 2024 · 0 comments
Assignees

Comments

@jamestalton
Copy link
Contributor

jamestalton commented Jan 10, 2024

https://stackoverflow.com/questions/39879680/example-of-setting-webpack-public-path-at-runtime

Make it so that the index.html can specify the public path

    <script type="application/javascript">
        window.resourceBasePath = '/path/to/scripts/on/server/';
    </script>

Then add in the code support that.

The nginx config could possible then use a substitution filter to update the public path when serving the index.html
https://nginx.org/en/docs/http/ngx_http_sub_module.html

This would allow the UI to be served from dynamic paths on a server.

@jamestalton jamestalton self-assigned this Jan 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant