Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(warn): Warn on colon shorthand usage on directive (fix #10191) #10199

Open
wants to merge 4 commits into
base: dev
Choose a base branch
from
Prev Previous commit
Next Next commit
Update test/unit/modules/compiler/parser.spec.js
Co-Authored-By: Eduardo San Martin Morote <posva@users.noreply.github.com>
  • Loading branch information
afontcu and posva committed Jun 26, 2019
commit 2279242b7a31e52f13890988420116979cccc371
2 changes: 1 addition & 1 deletion test/unit/modules/compiler/parser.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -530,7 +530,7 @@ describe('parser', () => {
expect(ast.props[0].value).toBe('msg')
})

it('v-bind expression on directive', () => {
it('warns when using v-bind shorthand on a directive', () => {
parse('<div :v-if="foo"></div>', baseOptions)
expect(`A v-bind shorthand directive was used on another Vue directive. Did you want to write 'v-if="foo"'?`).toHaveBeenWarned()
})
Expand Down