Skip to content

Commit 7c2ce6d

Browse files
committed
collect gives depcrecate warning
1 parent 63db4a6 commit 7c2ce6d

File tree

2 files changed

+7
-3
lines changed

2 files changed

+7
-3
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "vua-redux",
3-
"version": "0.3.0",
3+
"version": "0.4.0",
44
"description": "vue redux binding higher order component",
55
"author": "Nadim Tuhin",
66
"repository": {

src/connect.js

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -60,11 +60,15 @@ export default function connect(mapStateToProps = noop, mapActionsToProps = noop
6060

6161
/** @namespace children.collect */
6262
if (children.collect) {
63-
console.warn('vua-redux: collect is deprecated, use props');
6463
children.props = {
6564
...normalizeProps(children.props || {}),
6665
...normalizeProps(children.collect || {})
67-
}
66+
};
67+
68+
const msg = `vua-redux: collect is deprecated, use props ` +
69+
`in ${children.name || 'anonymous'} component`;
70+
71+
console.warn(msg);
6872
}
6973

7074
return {

0 commit comments

Comments
 (0)