Skip to content

Commit

Permalink
Backport PR matplotlib#25286: DOC: add cache-busting query to switche…
Browse files Browse the repository at this point in the history
…r json url
  • Loading branch information
ksunden authored and meeseeksmachine committed Feb 22, 2023
1 parent f4eac94 commit 24013b0
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion doc/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -397,7 +397,11 @@ def js_tag_with_cache_busting(js):
"collapse_navigation": not is_release_build,
"show_prev_next": False,
"switcher": {
"json_url": "https://matplotlib.org/devdocs/_static/switcher.json",
# Add a unique query to the switcher.json url. This will be ignored by
# the server, but will be used as part of the key for caching by browsers
# so when we do a new minor release the switcher will update "promptly" on
# the stable and devdocs.
"json_url": f"https://matplotlib.org/devdocs/_static/switcher.json?{SHA}",
"version_match": (
# The start version to show. This must be in switcher.json.
# We either go to 'stable' or to 'devdocs'
Expand Down

0 comments on commit 24013b0

Please sign in to comment.