proposal for validation pages

This commit is contained in:
Ilya 2017-04-04 14:25:48 +03:00 committed by GitHub
parent 89edc32298
commit 42e16a650b

View File

@ -129,8 +129,9 @@ function render (to, from, next) {
if (!isValid) return if (!isValid) return
if (typeof Component.options.validate !== 'function') return if (typeof Component.options.validate !== 'function') return
isValid = Component.options.validate({ isValid = Component.options.validate({
params: to.params || {}, params : to.params || {},
query: to.query || {} query : to.query || {},
store : context.store.state || {}
}) })
}) })
if (!isValid) { if (!isValid) {