@erickmerchant/framework
Advanced tools
Comparing version 3.0.0 to 3.0.1
@@ -7,11 +7,9 @@ 'use strict'; | ||
function framework(_ref) { | ||
module.exports = function (_ref) { | ||
var target = _ref.target; | ||
var store = _ref.store; | ||
var component = _ref.component; | ||
var methods = _ref.methods; | ||
var href = void 0; | ||
methods.show = singlePage(function (h) { | ||
var show = singlePage(function (h) { | ||
href = h; | ||
@@ -22,21 +20,17 @@ | ||
catchLinks(target, methods.show); | ||
catchLinks(target, show); | ||
methods.dispatch = function () { | ||
function dispatch() { | ||
render(store.apply(undefined, arguments)); | ||
}; | ||
} | ||
function render(state) { | ||
var element = component.call(methods, { state: state, href: href }); | ||
var element = component({ state: state, dispatch: dispatch, href: href, show: show, html: html, next: next }); | ||
html.update(target, element); | ||
} | ||
} | ||
}; | ||
framework.html = html; | ||
framework.next = function (callback) { | ||
function next(callback) { | ||
process.nextTick(callback); | ||
}; | ||
module.exports = framework; | ||
} |
{ | ||
"name": "@erickmerchant/framework", | ||
"version": "3.0.0", | ||
"version": "3.0.1", | ||
"description": "redux, hyperx, singlepage, catchlinks, etc", | ||
@@ -5,0 +5,0 @@ "main": "dist/main.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
3135
50