Skip to content

Conversation

@clydin
Copy link
Member

@clydin clydin commented Jan 24, 2025

In some cases a change to a component template may cause changes to other aspects of the application. Tailwind, for instance, may cause changes to the global stylesheets when class usage is changed in a template. To support hot module replacement of the component template in these cases, stylesheet changes are now analyzed and separated during the update process. This allows both a hot update of the template and the global stylesheet during the rebuild instead of the previously required full page reload.

Closes #29440

@clydin clydin added the target: patch This PR is targeted for the next patch release label Jan 24, 2025
@clydin clydin marked this pull request as ready for review January 27, 2025 00:09
…l stylesheet changes

In some cases a change to a component template may cause changes to other
aspects of the application. Tailwind, for instance, may cause changes to the
global stylesheets when class usage is changed in a template. To support hot
module replacement of the component template in these cases, stylesheet changes
are now analyzed and separated during the update process. This allows both a hot
update of the template and the global stylesheet during the rebuild instead
of the previously required full page reload.
@clydin clydin force-pushed the hmr/template-global-styles branch from 76a3edc to 33996b6 Compare January 27, 2025 14:15
@clydin clydin requested a review from alan-agius4 January 27, 2025 14:15
@clydin clydin added the action: review The PR is still awaiting reviews from at least one requested reviewer label Jan 27, 2025
Copy link
Collaborator

@alan-agius4 alan-agius4 left a comment

Choose a reason for hiding this comment

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

LGTM

@alan-agius4 alan-agius4 added action: merge The PR is ready for merge by the caretaker and removed action: review The PR is still awaiting reviews from at least one requested reviewer labels Jan 27, 2025
@alan-agius4 alan-agius4 merged commit 531dcdc into angular:main Jan 27, 2025
32 checks passed
@alan-agius4
Copy link
Collaborator

The changes were merged into the following branches: main, 19.1.x

@clydin clydin deleted the hmr/template-global-styles branch January 27, 2025 14:51
@angular-automatic-lock-bot
Copy link

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Feb 27, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

action: merge The PR is ready for merge by the caretaker area: @angular/build target: patch This PR is targeted for the next patch release

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Angular 19.1.3 Component HMR + TailwindCSS Problem - Not HMR but destructive refresh

2 participants