create-app
Advanced tools
Comparing version 0.1.6 to 0.2.0
@@ -109,13 +109,4 @@ 'use strict'; | ||
var initController = createInitController(location); | ||
var Controller = loader(controller, location, context); | ||
var Controller = null; | ||
if (controllerType === 'string') { | ||
Controller = loader(controller, location); | ||
} else if (controllerType === 'function') { | ||
Controller = controller(location, loader); | ||
} else { | ||
throw new Error('controller must be string or function'); | ||
} | ||
if (_.isThenable(Controller)) { | ||
@@ -122,0 +113,0 @@ return Controller.then(initController); |
@@ -125,12 +125,3 @@ 'use strict'; | ||
var controllerType = typeof controller === 'undefined' ? 'undefined' : _typeof(controller); | ||
var Controller = null; | ||
if (controllerType === 'string') { | ||
Controller = loader(controller, location); | ||
} else if (controllerType === 'function') { | ||
Controller = controller(location, loader); | ||
} else { | ||
throw new Error('controller must be string or function'); | ||
} | ||
var Controller = loader(controller, location, context); | ||
var finalContext = _extends({}, context, injectContext); | ||
@@ -137,0 +128,0 @@ |
@@ -15,3 +15,6 @@ 'use strict'; | ||
context: {}, | ||
type: 'createHistory' | ||
type: 'createHashHistory', | ||
loader: function loader(value) { | ||
return value; | ||
} | ||
}; |
{ | ||
"name": "create-app", | ||
"version": "0.1.6", | ||
"version": "0.2.0", | ||
"description": "configuring once, rendering both client and server.", | ||
@@ -5,0 +5,0 @@ "browser": "lib/client/index.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
32678
703