xxiao2018 opened a new pull request, #4735: URL: https://github.com/apache/doris-website/pull/4735
## Summary - Preload route JS on mouse hover, keyboard focus, or touch. This reduces the number of route files fetched while a page is idle. - Store each group of translated routes once in the client entry. - Load search indexes on interaction. Assign document IDs deterministically and name each index by its contents so it can be reused across releases. - Give content-addressed assets a one-year immutable cache policy. Publish HTML and search manifests with a one-hour policy. - Serve Inter and JetBrains Mono as WOFF2. ## Verification | Change | Local result | | --- | --- | | Route JS | Distinct CDN JS URLs requested while idle fell from 284 to 9 on the English homepage and from 306 to 21 on the desktop docs page. Keyboard focus still loaded chunks, and clicking opened the target. | | Entry bundle | The full-version English client entry fell from 13.53 MB to 8.11 MB, below the CDN's 10 MB edge compression limit. Local gzip produced 1.07 MB. | | Search | The docs and empty search pages went from one idle index request to zero. Changing only the Git revision preserved the URLs and bytes for 11 English and 6 Japanese fixture indexes. | | Caching | In Chromium with a simulated resource age over one hour, the short policy made a conditional request and received HTTP 304. The immutable policy reused the cached response without a second request. | | Fonts | Combined font size fell from 1.17 MB to 463 KB. Character coverage and variable font axes match the original files. | - Passed 85 Node tests, 8 Python tests, and 36 browser search scenarios across five languages. - Compared homepage-to-blog and docs-to-next-page navigation in Chromium at 100 ms simulated latency and 10 Mbps download. Measured times stayed within single-digit milliseconds of the baseline. The first search now fetches the index when needed. - Production CDN response headers and billing changes can be assessed after rollout. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
