Support of $bind with nested key path
See original GitHub issueI intend to $bind
a collection of documents under docs
by id
. It seems to work, and wonder if it is supported officially.
const documents = db.collection('documents')
export default {
props: ['documentId'],
data: () => ({ docs: { }}),
},
watch: {
documentId(id) {
// $bind automatically unbinds the previously bound property
this.$bind(`docs.${id}`, documents.doc(id))
},
},
}
Issue Analytics
- State:
- Created 4 years ago
- Comments:5 (3 by maintainers)
Top Results From Across the Web
WPF: How to bind to a nested property? - Stack Overflow
Easiest way would be to set the DataContext after you've initialized in the code behind rather than in XAML. That makes sense because...
Read more >Go.Binding and nested properties - GoJS - Northwoods Software
Hi Does go.Binding support binding to nested properties such as new go.Binding("text", "queryResult.value")? Currently, in order to produce ...
Read more >Bind to nested properties - Unity - Manual
This example demonstrates how to use the binding-path attribute of a BindableElement in UXML to bind fields to nested properties of a SerializedObject....
Read more >Bind to nested (navigation) properties in complex objects
How do I use complex objects in my model and show nested (navigation) properties information in the grid? Solution. Set the Field parameter...
Read more >Binding with nested objects is not working properly
This code snippets were working with the older version, but not with the new one. The selected item will not be set properly....
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@posva Thanks for the pointer, I manage to get it working with:
I noticed that when binding this way, $bind always return
undefined
instead ofPromise<Object>
as per documentation.I would also propose having a topic on “Dynamic binding with
Vue.set
” in the documentation as this is common use-case.Added to the roadmap #145 🙂