Skip to content

nested v-for by component and template bug #3810

Closed
@toxic-johann

Description

@toxic-johann

Vue.js version

2.0-rc8 / 2.0-rc7

Reproduction Link

https://codepen.io/toxic-johann/pen/JRJgGJ?editors=1111

Steps to reproduce

use a v-for to render component
in component, you have to write a v-for with template in it but not wrapped with a root element
open console, and run test() function

What is Expected?

open console, and run success() function
or you can click https://codepen.io/toxic-johann/pen/JRJgGJ?editors=1111.
when i keep on one root element in v-for, the problem dispear.

So I think, if vue consider multiple element int the template is forbidden.It should throw a warn.
Otherwise, it's a bug

What is actually happening?

throw the warning

[Vue warn]: It seems there are duplicate keys that is causing an update error. Make sure each v-for item has a unique key.
and error
Uncaught (in promise) TypeError: Cannot read property 'tag' of undefined

it's the same problem with #3807
u can reopen that.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions