@cicada/render
Advanced tools
Comparing version 1.1.8-alpha20 to 1.1.8-alpha21
@@ -118,3 +118,3 @@ 'use strict'; | ||
var _this = (0, _possibleConstructorReturn3.default)(this, (Wrapper.__proto__ || (0, _getPrototypeOf2.default)(Wrapper)).call(this)); | ||
var _this = (0, _possibleConstructorReturn3.default)(this, (Wrapper.__proto__ || (0, _getPrototypeOf2.default)(Wrapper)).call(this, props, context)); | ||
@@ -130,3 +130,4 @@ _initialiseProps.call(_this); | ||
return {}; | ||
} : _props$getInitialStat; | ||
} : _props$getInitialStat, | ||
configProps = props.props; | ||
var _context$getScopes = context.getScopes, | ||
@@ -153,3 +154,3 @@ getScopes = _context$getScopes === undefined ? function () { | ||
_this.setupDefaultListeners(defaultListeners); | ||
_this.registerToContext(props, context, getInitialState); | ||
_this.registerToContext(props, context, getInitialState, configProps); | ||
return _this; | ||
@@ -160,3 +161,3 @@ } | ||
key: 'registerToContext', | ||
value: function registerToContext(props, context, getInitialState) { | ||
value: function registerToContext(props, context, getInitialState, configProps) { | ||
var statePath = this.getResolvedStatePath(context, props); | ||
@@ -168,3 +169,3 @@ var stateTree = context.stateTree, | ||
var finalGetInitialState = function finalGetInitialState() { | ||
return (0, _extends3.default)({}, getDefaultState(), getInitialState()); | ||
return (0, _extends3.default)({}, getDefaultState(), getInitialState(), configProps); | ||
}; | ||
@@ -171,0 +172,0 @@ // TODO pathGetter 中的 statePath 相关的应该由 stateTree 自己实现,另一部分算作外界附加上去的信息,两者要区分。 |
{ | ||
"name": "@cicada/render", | ||
"version": "1.1.8-alpha20", | ||
"version": "1.1.8-alpha21", | ||
"main": "./lib/index.js", | ||
@@ -5,0 +5,0 @@ "scripts": { |
383187
9335