Prevent infinite recursion when upgrading custom elements

This commit is contained in:
Patrick Shaughnessy 2020-01-22 18:44:33 -05:00
parent 24674687ac
commit 10869f66b5
3 changed files with 14 additions and 19 deletions

View file

@ -342,6 +342,10 @@ impl Element {
self.rare_data().as_ref()?.custom_element_definition.clone()
}
pub fn clear_custom_element_definition(&self) {
self.ensure_rare_data().custom_element_definition = None;
}
pub fn push_callback_reaction(&self, function: Rc<Function>, args: Box<[Heap<JSVal>]>) {
self.ensure_rare_data()
.custom_element_reaction_queue