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

better warning #1669

Closed
TerenceZ opened this issue Nov 2, 2015 · 1 comment
Closed

better warning #1669

TerenceZ opened this issue Nov 2, 2015 · 1 comment

Comments

@TerenceZ
Copy link

TerenceZ commented Nov 2, 2015

Since the commit 778734a, vue will always complain that fragment should not contain multiple attributes. However, I think the following props (for components) should not be warned:

  • slot
  • component props
  • event bindings

Consider the following example, slot, @custom-change, :prop should be passed, and :not-prop should be warned. The v-bind is a complexed case, because the object may contain some props and some attributes for element and dynamic:(.

<root>
  <child slot="child" @custom-change="onchange" :prop="prop" :not-prop v-bind="mixedWithSomeProps"></child>
</root>

<template id="child">
  <inner-comp>
    <!-- something -->
  </inner-comp>
</template>
@yyx990803
Copy link
Member

Props are stripped before reaching the warning check, so no need to worry about them :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants