1 2!function(global,factory){"object"==typeof exports&&"undefined"!=typeof module?module.exports=factory():"function"==typeof define&&define.amd?define(factory):(global=global||self).toast=factory()}(this,function(){"use strict";return new(function(){function Toast(){}return Toast.prototype.all=function(urls){var _this=this;return Promise.all(urls.map(function(url){switch(url.split(".").pop().toLowerCase()){case"css":return _this.css(url);case"js":return _this.js(url);default:return Promise.reject(new Error("Unable to detect extension of '"+url+"'"))}}))},Toast.prototype.css=function(url){var link=document.createElement("link");return link.rel="stylesheet",link.href=url,document.querySelector("head").appendChild(link),this.promise(link)},Toast.prototype.js=function(url){var script=document.createElement("script");return script.src=url,document.querySelector("head").appendChild(script),this.promise(script)},Toast.prototype.promise=function(element){return new Promise(function(resolve,reject){element.addEventListener("load",function(){resolve(element)}),element.addEventListener("error",function(){reject()})})},Toast}())});
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.