Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

cooolar-base

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

cooolar-base - npm Package Compare versions

Comparing version 0.0.1 to 0.0.11

src/core/core.js

62

build/cooolar-base.dbg.js

@@ -1634,2 +1634,62 @@ /**

var ScriptHandler = function () {
function ScriptHandler() {
}
ScriptHandler._push = function _push(Type) {};
var _proto = ScriptHandler.prototype;
_proto.load = function load(url, options, callback) {
if (typeof url === 'string') {
url = {
load: url,
original: url
};
}
if (typeof options === 'function') {
callback = options;
options = {};
}
this._loadScript(url.load, options, function (err, extra) {
if (!err) {
callback(null, extra);
} else {
callback(err);
}
});
};
_proto._loadScript = function _loadScript(url, options, callback) {
var head = document.head;
var element = document.createElement('script');
if (options.async == null) {
options.async = true;
}
element.async = options.async;
element.addEventListener('error', function (e) {
callback("Script: " + e.target.src + " failed to load");
}, false);
var done = false;
element.onload = element.onreadystatechange = function () {
if (!done && (!this.readyState || this.readyState === 'loaded' || this.readyState === 'complete')) {
done = true;
callback(null, element);
}
};
element.src = url;
head.appendChild(element);
};
return ScriptHandler;
}();
var scriptHandler = new ScriptHandler();
exports.EventHandler = EventHandler;

@@ -1639,2 +1699,3 @@ exports.Http = Http;

exports.ReadStream = ReadStream;
exports.ScriptHandler = ScriptHandler;
exports.SortedLoopArray = SortedLoopArray;

@@ -1659,2 +1720,3 @@ exports.Tags = Tags;

exports.revision = revision;
exports.scriptHandler = scriptHandler;
exports.string = string;

@@ -1661,0 +1723,0 @@ exports.type = type;

2

package.json
{
"name": "cooolar-base",
"version": "0.0.1",
"version": "0.0.11",
"description": "",

@@ -5,0 +5,0 @@ "keywords": [

@@ -0,0 +0,0 @@ >CooolAR Base

@@ -0,0 +0,0 @@ import babel from '@rollup/plugin-babel';

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc