mirror of
https://github.com/discourse/discourse.git
synced 2024-11-26 03:23:38 +08:00
df5561d780
In development, Ember raises an error when previously-used values are updated during a render. This is to avoid 'backtracking', where parts of templates have to be re-rendered multiple times. In general, this kind of pattern should be avoided, and Ember's warning helps us do that. However, for the deprecation warning banner, it is quite reasonable for some rendering to trigger a deprecation, and thereby require the global-notice to be re-rendered. We can use our `DeferredTrackedSet` to achieve that. Its `.add` method will delay adding an item to the Set until after the current render has completed. |
||
---|---|---|
.. | ||
images | ||
javascripts | ||
stylesheets |