model icon indicating copy to clipboard operation
model copied to clipboard

type: Array, parse 返回异常

Open mlinquan opened this issue 5 years ago • 0 comments

import Model from 'js-model'

const modelTest = new Model({
  a: {
      type: Array,
      defalut: []
  }
})

console.log(modelTest.parse({}))

返回结果

{
    a: {
      type: null,
      defalut: Array(0)
    }
}

正常不应该是返回

{
    a: []
}

吗?

mlinquan avatar Apr 29 '21 05:04 mlinquan