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

Support nested paths as keys #152

Open
morrislaptop opened this issue Jan 16, 2018 · 4 comments
Open

Support nested paths as keys #152

morrislaptop opened this issue Jan 16, 2018 · 4 comments
Labels
feature request options api This relates only to Options API usage

Comments

@morrislaptop
Copy link

I'm using geofire and when an object enters into my radius I want to fetch the details and pop it into an array.

Something like:

    this.geoquery.on('key_entered', (key, location, distance) => {
      this.$bindAsObject(`contacts.${key}`, firebase.database().ref(`contacts/${key}`))
    })

However is just creates a variable on the instance with the literal string so I can't iterate through contacts.

Is there a suggested way of doing this?

@posva
Copy link
Member

posva commented Jan 16, 2018

Right now, you need to use something as this.$bindAsObject(`contacts_${key}`). Handling deep paths (my.nested.array.0.property) may be supported in future releases

@posva posva changed the title $bindAsObject into dynamic key Support nested paths as keys Jan 16, 2018
@franciscolourenco

This comment has been minimized.

@posva

This comment has been minimized.

@dominik-korsa
Copy link

Is there any progress on this?

@posva posva added the options api This relates only to Options API usage label Jul 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature request options api This relates only to Options API usage
Projects
None yet
Development

No branches or pull requests

4 participants