<h3 dir="auto">What problem does this feature solve?</h3>
<p dir="auto">It's quite frequent we need to abstract a v-for'ed element tree as a component</p>
<p dir="auto">for example, go from <code class="notranslate">&lt;li v-for="item in list"&gt;(something reusable)&lt;/li&gt;</code> to <code class="notranslate">&lt;ListItem v-for="item in list" :key="item"&gt;</code></p>
<p dir="auto">it's extremely useful when you are building higher older components. i.e. Components that glues components with predefined interfaces.</p>
<p dir="auto">it used to be natural to do so, as objects always come with an identity, which is automatically unique, and best suited to be keys.</p>
<p dir="auto">But now, it says it should be a primitive — therefore I have to patch the object creation system of javascript to manually give every object created an id property, which is a number automatically increases every time a new object is created, and it is duplicate with the identity an object already have.</p>
<p dir="auto">And the counter has to be global, as every object created potentially passed to v-for has to be patched.</p>
<p dir="auto">This is havoc</p>
<p dir="auto">It utterly destroys the usefulness of v-for and the convenience of abstraction and code reuse, it also breaks tunes of existing code.</p>
<p dir="auto">It seems that it's much easier to implement my own v-for that supports the identity of objects as keys rather than patching the object system of javascript to ensure every object has a duplicated unique primitive to make vue happy. And it's much easier to do so as I have tons of code broken by this primitive check, which needs a complete and unnecessary redesign. And the complexity increases dramatically.</p>
<p dir="auto">So PLEEEASE just support plain objects, i.e. objects created by object literal</p>
<p dir="auto">they are absolutely the same with primitives when all your diff algorithm needs is just <code class="notranslate">SameValue</code>. It's nothing difficult to implement.</p>
<p dir="auto">But for us, it's invaluable.</p>
<h3 dir="auto">What does the proposed API look like?</h3>
<p dir="auto"><code class="notranslate">&lt;component v-for="item in [{...}, {...}]" :key="item"&gt;</code></p>
<p dir="auto">Just support objects as v-for's keys</p>
<p dir="auto">Simple yet useful</p>
<h3 dir="auto">Vue.js version</h3>
<p dir="auto">2.0.2</p>
<h3 dir="auto">Reproduction Link</h3>
<p dir="auto"><a href="http://jsfiddle.net/2vqkLkjL/1/" rel="nofollow">http://jsfiddle.net/2vqkLkjL/1/</a></p>
<h3 dir="auto">Steps to reproduce</h3>
<ul dir="auto">
<li>Create a component with a nested data property: Object, of an object containing an array.</li>
<li>Set up watcher for this property, specifying the deep flag.</li>
</ul>
<h3 dir="auto">What is Expected?</h3>
<p dir="auto">When the value of an array changes, the watcher runs</p>
<h3 dir="auto">What is actually happening?</h3>
<p dir="auto">Watcher isn't getting triggered.</p>
<p dir="auto">The code seemed to work fine in Vue 1.x.</p>
<p dir="auto">Not 100% nested objects/arrays is the correct way for managing a view with lots of inputs.</p>