mirror of
https://github.com/sveltejs/svelte.git
synced 2024-12-01 17:30:59 +01:00
Merge pull request #1868 from 6eDesign/master
Small update to allow class directives to work in IE11
This commit is contained in:
commit
811aa31909
@ -239,5 +239,5 @@ export function addResizeListener(element, fn) {
|
||||
}
|
||||
|
||||
export function toggleClass(element, name, toggle) {
|
||||
element.classList.toggle(name, !!toggle);
|
||||
element.classList[toggle ? 'add' : 'remove'](name);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user