Commit 57ad9f1
committed
Block editor: Cache global stylesheet by theme key.
Global styles are used in a few different contexts (front, editor, customizer, the theme directory). In the last two contexts, it's important that switching themes immediately refreshes the global stylesheet, to avoid situations in which the styles of the previous theme load with the new one. This was brought up at WordPress/gutenberg#34531 (customizer) and at meta.trac.wordpress.org/ticket/5818 (theme directory).
This commit makes sure the stylesheet is regenerated upon switching themes.
Props oandregal, dd32.
See #53175.
git-svn-id: https://develop.svn.wordpress.org/trunk@51819 602fd350-edb4-49c9-b593-d223f7449a821 parent 97790af commit 57ad9f1
1 file changed
+3
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2300 | 2300 | | |
2301 | 2301 | | |
2302 | 2302 | | |
| 2303 | + | |
2303 | 2304 | | |
2304 | | - | |
| 2305 | + | |
2305 | 2306 | | |
2306 | 2307 | | |
2307 | 2308 | | |
| |||
2313 | 2314 | | |
2314 | 2315 | | |
2315 | 2316 | | |
2316 | | - | |
| 2317 | + | |
2317 | 2318 | | |
2318 | 2319 | | |
2319 | 2320 | | |
| |||
0 commit comments