New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@cycle/dom

Package Overview
Dependencies
Maintainers
2
Versions
155
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@cycle/dom - npm Package Compare versions

Comparing version 15.0.0-rc.1 to 15.0.0-rc.2

snabbdom-to-html.d.ts

30

.testem.json

@@ -12,3 +12,3 @@ {

"exe": "./node_modules/.bin/saucie",
"args": ["-b", "chrome", "-p", "Windows 10", "-v", "latest", "--no-ct", "--at", "-u"],
"args": ["-b", "chrome", "-p", "Windows 10", "-v", "latest", "--no-connect", "--attach", "-u"],
"protocol": "browser"

@@ -18,3 +18,3 @@ },

"exe": "./node_modules/.bin/saucie",
"args": ["-b", "firefox", "-p", "Windows 10", "-v", "latest", "--no-ct", "--at", "-u"],
"args": ["-b", "firefox", "-p", "Windows 10", "-v", "latest", "--no-connect", "--attach", "-u"],
"protocol": "browser"

@@ -24,3 +24,3 @@ },

"exe": "./node_modules/.bin/saucie",
"args": ["-b", "safari", "-v", "9", "--no-ct", "--at", "-u"],
"args": ["-b", "safari", "-v", "9", "--no-connect", "--attach", "-u"],
"protocol": "browser"

@@ -30,3 +30,3 @@ },

"exe": "./node_modules/.bin/saucie",
"args": ["-b", "chrome", "-p", "Windows 10", "-v", "49", "--no-ct", "--at", "-u"],
"args": ["-b", "chrome", "-p", "Windows 10", "-v", "49", "--no-connect", "--attach", "-u"],
"protocol": "browser"

@@ -36,3 +36,3 @@ },

"exe": "./node_modules/.bin/saucie",
"args": ["-b", "chrome", "-p", "Windows 10", "-v", "50", "--no-ct", "--at", "-u"],
"args": ["-b", "chrome", "-p", "Windows 10", "-v", "50", "--no-connect", "--attach", "-u"],
"protocol": "browser"

@@ -42,3 +42,3 @@ },

"exe": "./node_modules/.bin/saucie",
"args": ["-b", "iphone", "-v", "8.4", "--no-ct", "--at", "-u"],
"args": ["-b", "iphone", "-v", "8.4", "--no-connect", "--attach", "-u"],
"protocol": "browser"

@@ -48,13 +48,8 @@ },

"exe": "./node_modules/.bin/saucie",
"args": ["-b", "iphone", "-v", "9.1", "--no-ct", "--at", "-u"],
"args": ["-b", "iphone", "-v", "9.1", "--no-connect", "--attach", "-u"],
"protocol": "browser"
},
"SL_android_4_4": {
"exe": "./node_modules/.bin/saucie",
"args": ["-b", "android", "-p", "Linux", "-v", "4.4", "--no-ct", "--at", "-u"],
"protocol": "browser"
},
"SL_android_5_1": {
"exe": "./node_modules/.bin/saucie",
"args": ["-b", "android", "-p", "Linux", "-v", "5.1", "--no-ct", "--at", "-u"],
"args": ["-b", "android", "-p", "Linux", "-v", "5.1", "--no-connect", "--attach", "-u"],
"protocol": "browser"

@@ -64,3 +59,3 @@ },

"exe": "./node_modules/.bin/saucie",
"args": ["-b", "safari", "-v", "8", "--no-ct", "--at", "-u"],
"args": ["-b", "safari", "-v", "8", "--no-connect", "--attach", "-u"],
"protocol": "browser"

@@ -70,3 +65,3 @@ },

"exe": "./node_modules/.bin/saucie",
"args": ["-b", "microsoftedge", "--no-ct", "--at", "-u"],
"args": ["-b", "microsoftedge", "--no-connect", "--attach", "-u"],
"protocol": "browser"

@@ -76,3 +71,3 @@ },

"exe": "./node_modules/.bin/saucie",
"args": ["-b", "internet explorer", "-v", "11", "--no-ct", "--at", "-u"],
"args": ["-b", "internet explorer", "-v", "11", "--no-connect", "--attach", "-u"],
"protocol": "browser"

@@ -82,3 +77,3 @@ },

"exe": "./node_modules/.bin/saucie",
"args": ["-b", "internet explorer", "-v", "10", "--no-ct", "--at", "-u"],
"args": ["-b", "internet explorer", "-v", "10", "--no-connect", "--attach", "-u"],
"protocol": "browser"

@@ -102,3 +97,2 @@ }

"SL_android_5_1",
"SL_android_4_4",
"SL_IE_11",

@@ -105,0 +99,0 @@ "SL_IE_10"

@@ -0,1 +1,23 @@

<a name="15.0.0-rc.2"></a>
# 15.0.0-rc.2 (2017-02-03)
### Bug Fixes
* **dom:** fix isolation bug of child when parent is re-added ([e18e7f7](https://github.com/cyclejs/cyclejs/tree/master/packages/dom/commit/e18e7f7))
* **dom:** make cycle/run a hard dependency ([47f7f49](https://github.com/cyclejs/cyclejs/tree/master/packages/dom/commit/47f7f49))
* **dom:** report errors thrown in snabbdom hooks ([edb025c](https://github.com/cyclejs/cyclejs/tree/master/packages/dom/commit/edb025c))
* **dom:** rewrite for Cycle Unified ([47346b4](https://github.com/cyclejs/cyclejs/tree/master/packages/dom/commit/47346b4))
* **dom:** start snabbdom only when DOM is ready ([40d39dd](https://github.com/cyclejs/cyclejs/tree/master/packages/dom/commit/40d39dd))
* **dom:** support using DOMSource.elements() in isolated main() ([ca192b5](https://github.com/cyclejs/cyclejs/tree/master/packages/dom/commit/ca192b5))
* **dom:** update to snabbdom v0.6.3 ([d1077c8](https://github.com/cyclejs/cyclejs/tree/master/packages/dom/commit/d1077c8))
### Features
* **dom:** support passing custom modules to HTML driver ([f965de5](https://github.com/cyclejs/cyclejs/tree/master/packages/dom/commit/f965de5))
* **dom:** use snabbdom dataset module by default ([36759af](https://github.com/cyclejs/cyclejs/tree/master/packages/dom/commit/36759af))
<a name="14.3.0"></a>

@@ -2,0 +24,0 @@ # 14.3.0 (2016-12-21)

26

lib/mockDOMSource.js

@@ -21,14 +21,4 @@ "use strict";

MockedDOMSource.prototype.events = function (eventType, options) {
var mockConfig = this._mockConfig;
var keys = Object.keys(mockConfig);
var keysLen = keys.length;
for (var i = 0; i < keysLen; i++) {
var key = keys[i];
if (key === eventType) {
var out_1 = adapt_1.adapt(mockConfig[key]);
out_1._isCycleSource = 'MockedDOM';
return out_1;
}
}
var out = adapt_1.adapt(xstream_1.default.empty());
var streamForEventType = this._mockConfig[eventType];
var out = adapt_1.adapt(streamForEventType || xstream_1.default.empty());
out._isCycleSource = 'MockedDOM';

@@ -38,12 +28,4 @@ return out;

MockedDOMSource.prototype.select = function (selector) {
var mockConfig = this._mockConfig;
var keys = Object.keys(mockConfig);
var keysLen = keys.length;
for (var i = 0; i < keysLen; i++) {
var key = keys[i];
if (key === selector) {
return new MockedDOMSource(mockConfig[key]);
}
}
return new MockedDOMSource({});
var mockConfigForSelector = this._mockConfig[selector] || {};
return new MockedDOMSource(mockConfigForSelector);
};

@@ -50,0 +32,0 @@ MockedDOMSource.prototype.isolateSource = function (source, scope) {

{
"name": "@cycle/dom",
"version": "15.0.0-rc.1",
"version": "15.0.0-rc.2",
"description": "The standard DOM Driver for Cycle.js, based on Snabbdom",

@@ -36,2 +36,3 @@ "license": "MIT",

"dependencies": {
"@cycle/run": "*",
"es6-map": "^0.1.4",

@@ -47,15 +48,11 @@ "snabbdom": "0.6.3",

"@cycle/isolate": "1.x",
"@cycle/run": "1.0.0-rc.6",
"@cycle/rxjs-run": "4.0.0-rc.2",
"@cycle/rxjs-run": "4.0.0-rc.3",
"@types/mocha": "^2.2.33",
"@types/node": "^6.0.45",
"@types/node": "^7.0.4",
"@types/sinon": "^1.16.32",
"babel-plugin-jsx-factory": "^1.0.1",
"babel-plugin-syntax-jsx": "^6.3.13",
"babel-plugin-transform-react-jsx": "^6.4.0",
"rx": "^4.1.0",
"rxjs": "5.0.1",
"saucie": "^1.4.1",
"rxjs": "5.1.0",
"saucie": "3.1.0",
"simulant": "^0.2.2",
"snabbdom-jsx": "^0.3.0",
"string.prototype.startswith": "^0.2.0",
"xstream": "10.x.x"

@@ -74,3 +71,3 @@ },

"lint": "../node_modules/.bin/tslint -c ../tslint.json ./src/*.ts ./src/**/*.ts",
"prelib": "rm -rf lib/ && mkdir -p lib && ../node_modules/.bin/typings install",
"prelib": "rm -rf lib/ && mkdir -p lib",
"lib": "../node_modules/.bin/tsc",

@@ -93,3 +90,3 @@ "test-node": "../node_modules/.bin/mocha test/node/*.ts --require ts-node/register",

"test-wait": "npm run lint && npm run lib && npm run test-node && npm run test-browser-wait",
"browserify": "../node_modules/.bin/browserify lib/index.js -t babelify --global-transform=browserify-shim --standalone CycleDOM --exclude xstream --outfile dist/cycle-dom.js",
"browserify": "../node_modules/.bin/browserify lib/index.js --global-transform=browserify-shim --standalone CycleDOM --exclude xstream --outfile dist/cycle-dom.js",
"uglify": "../node_modules/.bin/uglifyjs dist/cycle-dom.js --compress --mangle -o dist/cycle-dom.min.js",

@@ -96,0 +93,0 @@ "predist": "rm -rf dist/ && mkdir -p dist/",

@@ -31,15 +31,7 @@ import xs, {Stream, MemoryStream} from 'xstream';

public events(eventType: string, options?: EventsFnOptions): any {
const mockConfig = this._mockConfig;
const keys = Object.keys(mockConfig);
const keysLen = keys.length;
for (let i = 0; i < keysLen; i++) {
const key = keys[i];
if (key === eventType) {
const out: DevToolEnabledSource & FantasyObservable = adapt(mockConfig[key] as any);
out._isCycleSource = 'MockedDOM';
return out;
}
}
const out: DevToolEnabledSource & FantasyObservable = adapt(xs.empty());
const streamForEventType = this._mockConfig[eventType] as any;
const out: DevToolEnabledSource & FantasyObservable = adapt(streamForEventType || xs.empty());
out._isCycleSource = 'MockedDOM';
return out;

@@ -49,12 +41,5 @@ }

public select(selector: string): MockedDOMSource {
const mockConfig = this._mockConfig;
const keys = Object.keys(mockConfig);
const keysLen = keys.length;
for (let i = 0; i < keysLen; i++) {
const key = keys[i];
if (key === selector) {
return new MockedDOMSource(mockConfig[key] as MockConfig);
}
}
return new MockedDOMSource({} as MockConfig);
const mockConfigForSelector = this._mockConfig[selector] || {};
return new MockedDOMSource(mockConfigForSelector as MockConfig);
}

@@ -61,0 +46,0 @@

@@ -9,2 +9,3 @@ "use strict";

var lib_1 = require("../../../lib");
require('string.prototype.startswith');
function createRenderTarget(id) {

@@ -11,0 +12,0 @@ if (id === void 0) { id = null; }

@@ -43,2 +43,3 @@ "use strict";

it('should support snabbdom dataset module by default', function (done) {
var thisBrowserSupportsDataset = typeof document.createElement('DIV').dataset !== 'undefined';
function app(sources) {

@@ -51,20 +52,25 @@ return {

}
var _a = run_1.setup(app, {
DOM: lib_1.makeDOMDriver(createRenderTarget()),
}), sinks = _a.sinks, sources = _a.sources, run = _a.run;
var dispose;
sources.DOM.select(':root').elements().drop(1).take(1).addListener({
next: function (root) {
var elem = root.querySelector('.my-class');
assert.notStrictEqual(elem, null);
assert.notStrictEqual(typeof elem, 'undefined');
assert.strictEqual(elem.tagName, 'DIV');
assert.strictEqual(elem.dataset['foo'], 'Foo');
setTimeout(function () {
dispose();
done();
});
},
});
dispose = run();
if (!thisBrowserSupportsDataset) {
done();
}
else {
var _a = run_1.setup(app, {
DOM: lib_1.makeDOMDriver(createRenderTarget()),
}), sinks = _a.sinks, sources = _a.sources, run_2 = _a.run;
var dispose_1;
sources.DOM.select(':root').elements().drop(1).take(1).addListener({
next: function (root) {
var elem = root.querySelector('.my-class');
assert.notStrictEqual(elem, null);
assert.notStrictEqual(typeof elem, 'undefined');
assert.strictEqual(elem.tagName, 'DIV');
assert.strictEqual(elem.dataset['foo'], 'Foo');
setTimeout(function () {
dispose_1();
done();
});
},
});
dispose_1 = run_2();
}
});

@@ -236,4 +242,4 @@ it('should convert a simple virtual-dom <select> to DOM element', function (done) {

DOM: lib_1.makeDOMDriver(createRenderTarget()),
}), sinks = _a.sinks, sources = _a.sources, run_2 = _a.run;
var dispose_1;
}), sinks = _a.sinks, sources = _a.sources, run_3 = _a.run;
var dispose_2;
// Make assertions

@@ -247,3 +253,3 @@ sources.DOM.select(':root').elements().drop(1).take(1).addListener({

setTimeout(function () {
dispose_1();
dispose_2();
done();

@@ -253,3 +259,3 @@ });

});
dispose_1 = run_2();
dispose_2 = run_3();
}

@@ -256,0 +262,0 @@ });

@@ -21,2 +21,3 @@ import * as assert from 'assert';

} from '../../../lib';
require('string.prototype.startswith');

@@ -23,0 +24,0 @@ function createRenderTarget(id: string | null = null) {

@@ -27,6 +27,5 @@ {

"files": [
"node_modules/rx/ts/rx.all.d.ts",
"typings/index.d.ts",
"./snabbdom-to-html.d.ts",
"src/index.ts"
]
}

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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