mirror of
https://github.com/SerenityOS/serenity
synced 2026-05-05 22:52:10 +02:00
LibWeb: Set script force async to false when async changes
(cherry picked from commit bedb626c29913f4e355dfd50c29194e15ed71561)
This commit is contained in:
committed by
Nico Weber
parent
ceebaac9ef
commit
d81af2f5f5
@@ -66,6 +66,10 @@ void HTMLScriptElement::attribute_changed(FlyString const& name, Optional<String
|
||||
if (!is_parser_inserted() && is_connected() && value.has_value() && !old_value.has_value()) {
|
||||
prepare_script();
|
||||
}
|
||||
} else if (name == HTML::AttributeNames::async) {
|
||||
// https://html.spec.whatwg.org/multipage/scripting.html#script-processing-model:script-force-async
|
||||
// When an async attribute is added to a script element el, the user agent must set el's force async to false.
|
||||
m_force_async = false;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user