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

keen-core

Package Overview
Dependencies
Maintainers
1
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

keen-core - npm Package Compare versions

Comparing version 0.0.2 to 0.0.3

lib/async-loader.js

16

gulpfile.js

@@ -21,12 +21,9 @@ var gulp = require('gulp'),

return browserify({
entries: './test/index.js',
entries: './lib/index.js',
debug: true
})
.bundle()
.pipe(source('bundle.js'))
.pipe(source('keen-core.js'))
.pipe(buffer())
.pipe(compress())
.on('error', gutil.log)
.pipe(sourcemaps.init({ loadMaps: true }))
.pipe(sourcemaps.write('./'))
.pipe(gulp.dest('./test'));

@@ -84,4 +81,11 @@ });

.pipe(tapeRunner())
.on('error', gutil.log)
.on('results', gutil.log)
.pipe(process.stdout);
.pipe(process.stdout)
.pipe(source('bundle.js'))
.pipe(buffer())
// .pipe(compress())
.pipe(sourcemaps.init({ loadMaps: true }))
.pipe(sourcemaps.write('./'))
.pipe(gulp.dest('./test'));
});

@@ -88,0 +92,0 @@

@@ -58,2 +58,11 @@ var each = require('./utils/each'),

Client.ready = function(fn){
if (Client.loaded) {
fn();
}
else {
Client.once('ready', fn);
}
};
Client.prototype.configure = function(obj){

@@ -145,2 +154,34 @@ var config = obj || {};

domReady(function(){
Client.loaded = true;
Client.emit('ready');
});
function domReady(fn){
if (Client.loaded || typeof document === 'undefined') {
fn();
return;
}
// Firefox 3.5 shim
if(document.readyState == null && document.addEventListener){
document.addEventListener('DOMContentLoaded', function DOMContentLoaded(){
document.removeEventListener('DOMContentLoaded', DOMContentLoaded, false);
document.readyState = 'complete';
}, false);
document.readyState = 'loading';
}
testDom(fn);
}
function testDom(fn){
if (/in/.test(document.readyState)) {
setTimeout(function(){
testDom(fn);
}, 9);
}
else {
fn();
}
}
// Module Definitions

@@ -159,9 +200,4 @@ // --------------------

// RequireJS
if (typeof define !== 'undefined' && define.amd) {
define('keen-core', [], function(){
return Client;
});
}
/* RequireJS defintion not necessary */
}).call(this, typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {});
{
"name": "keen-core",
"version": "0.0.2",
"version": "0.0.3",
"description": "Core functionality powering Keen IO's modular JavaScript SDKs",

@@ -5,0 +5,0 @@ "main": "lib/index.js",

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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