Skip to content

Conversation

@oandregal
Copy link
Member

@oandregal oandregal commented Sep 9, 2021

Ticket: https://core.trac.wordpress.org/ticket/53175

Props to @dd32

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 https://meta.trac.wordpress.org/ticket/5818 (theme directory).

This PR makes sure the stylesheet is regenerated upon switching themes.

@oandregal
Copy link
Member Author

cc @jorgefilipecosta @gziolo

Copy link
Member

@jorgefilipecosta jorgefilipecosta left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍

@oandregal
Copy link
Member Author

I don't think I have the permissions to commit this myself to the SVN. Can someone help with that?

Note that I'd like to give props to dd32 (it's in the issue description).

@jorgefilipecosta
Copy link
Member

I added committing this PR to core to my todo list will do it soon.

@jorgefilipecosta
Copy link
Member

Committed here 57ad9f1.

@oandregal oandregal closed this Sep 20, 2021
@oandregal oandregal deleted the fix/global-stylesheet-cache branch September 20, 2021 07:52
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

Successfully merging this pull request may close these issues.

2 participants