You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In PR #112 I modified the spec description for replace() to only return a promise instead of throwing, as noted in the TAG API guidelines (here). I believe that I accidentally changed the semantics in the case of a failed @import rule.
Intended Behavior
I believe that the intended behavior should be that if an @import rule fails to load, the promise is rejected with a network error, but the sheet's rules are still cleared.
Actual Behavior
The new text that I wrote in #112 would suggest that if the @import rule fails to load, the sheet still contains the rules it had previously.
I want to double check that the intended behavior is correct. If so, I will create a PR to amend the mistake that I made.
Note that step 3 in the old text clears the sheets rules. I believe that I inadvertently removed this action in what is now step 4 of the new text.
We’re not deprecating replace() entirely, just the case where the replacement sheet contains an @import rule. Calls to replace() without @import will continue working as is.
In PR #112 I modified the spec description for
replace()
to only return a promise instead of throwing, as noted in the TAG API guidelines (here). I believe that I accidentally changed the semantics in the case of a failed @import rule.Intended Behavior
I believe that the intended behavior should be that if an @import rule fails to load, the promise is rejected with a network error, but the sheet's rules are still cleared.
Actual Behavior
The new text that I wrote in #112 would suggest that if the @import rule fails to load, the sheet still contains the rules it had previously.
I want to double check that the intended behavior is correct. If so, I will create a PR to amend the mistake that I made.
Note that step 3 in the old text clears the sheets rules. I believe that I inadvertently removed this action in what is now step 4 of the new text.
Here are the rules before the change:
Here are the rules after the change:
cc @tabatkins @rakina
The text was updated successfully, but these errors were encountered: