-
Notifications
You must be signed in to change notification settings - Fork 1.6k
serve Splide and Three.js locally instead of via CDN #16557
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
base: master
Are you sure you want to change the base?
serve Splide and Three.js locally instead of via CDN #16557
Conversation
Hi @AritraDey-Dev. Thanks for your PR. I'm waiting for a istio member to verify that this patch is reasonable to test. If it is, they should reply with Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
It's been a few years since I raised the request. Does this actually make sense? Pros of CDN: loads quicker in parallel? |
Yes, definitely makes sense. The concern you mentioned—external changes breaking the site—is actually what's causing issues when the scripts are loaded from the static folder. That’s why I’ve marked this PR as a draft for now. There are a few UI breaking changes I’m still working through. Do you recommend I continue refining the PR and eventually open it for review? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/ok-to-test
Sure, go ahead. |
Up for review! |
Are these files going to be bundled/minified? (And if so, should we hold off on this until the esbuild PR has gone through?) |
These files are already minified,look at the extension
I believe we don't need to hold off until the esbuild PR goes through because these Splide files are used directly by HTML files and the esbuild PR is focused on changing js files, so they are independent changes. |
It's still JavaScript that we serve, and if we are going to have a single minified JS file which has its tree shaken, then we should have it only serve the code used by splide. Should we have some sort of npm pulling splide situation like we have for the others? By making this change we move from (That's not to say it's not worth doing, but we should look to do it properly if we are making any change.) |
makes sense! I think we can add the particular versions of Splide (4.1.4) and Three.js (0.162.0) to the |
Fixes istio#9723 Signed-off-by: Aritra Dey <[email protected]>
Signed-off-by: Aritra Dey <[email protected]>
Signed-off-by: Aritra Dey <[email protected]>
7fd9aa2
to
8c91bfd
Compare
I don't see Three.js here? |
I was thinking of adding Three.js via Docker tools and pinning the version that way. Would that be a better approach instead of adding |
Signed-off-by: Aritra Dey <[email protected]>
Fixes istio#9723 Signed-off-by: Aritra Dey <[email protected]>
Signed-off-by: Aritra Dey <[email protected]>
22a8f51
to
594e49d
Compare
Signed-off-by: Aritra Dey <[email protected]>
Signed-off-by: Aritra Dey <[email protected]>
@craigbox I've added three.js in netlify_install. If this approach looks better, I will go ahead and add it to the tools Dockerfile. Please let me know. |
@AritraDey-Dev: The following tests failed, say
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here. |
Description
Serve
Splide
andThree.js
locally via static directory to replace externalCDN
usage.Fixes #9723
Command run to download the css and js file -
Reviewers