Skip to content

Commit 0b222e6

Browse files
committed
https://github.com/gajus/react-css-modules/issues/46
1 parent 510b8d4 commit 0b222e6

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

dist/wrapStatelessFunction.js

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,9 @@ var wrapStatelessFunction = undefined;
3232
* @returns {function}
3333
*/
3434
wrapStatelessFunction = function (Component, defaultStyles, options) {
35-
return function () {
35+
var WrappedComponent = undefined;
36+
37+
WrappedComponent = function () {
3638
for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
3739
args[_key - 1] = arguments[_key];
3840
}
@@ -65,6 +67,10 @@ wrapStatelessFunction = function (Component, defaultStyles, options) {
6567

6668
return _react2['default'].createElement('noscript');
6769
};
70+
71+
(0, _lodashObjectAssign3['default'])(WrappedComponent, Component);
72+
73+
return WrappedComponent;
6874
};
6975

7076
exports['default'] = wrapStatelessFunction;

0 commit comments

Comments
 (0)