wip-feat: mercure alerts
This commit is contained in:
@@ -8,3 +8,13 @@ import './bootstrap.js';
|
||||
import './styles/app.css';
|
||||
|
||||
console.log('This log comes from assets/app.js - welcome to AssetMapper! 🎉');
|
||||
|
||||
let alert = document.querySelector('.alert');
|
||||
var observer = new MutationObserver(function(mutations) {
|
||||
if (document.contains(alert)) {
|
||||
observer.disconnect();
|
||||
}
|
||||
});
|
||||
|
||||
observer.observe(document, {attributes: false, childList: true, characterData: false, subtree:true});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user