Skip to content

Commit 982f03c

Browse files
committed
minor changes
1 parent eb9cbc8 commit 982f03c

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

index.js

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,13 +12,12 @@ var internalHooks = [
1212
]
1313

1414
function decorator (Component) {
15-
var capture = new Component(false)
1615
var options = {}
1716
// instance properties are data
18-
var fields = Object.keys(capture)
19-
if (fields.length) {
17+
var data = new Component()
18+
if (Object.keys(data).length) {
2019
options.data = function () {
21-
return clone(capture)
20+
return clone(data)
2221
}
2322
}
2423
// prototype props.

0 commit comments

Comments
 (0)