Shady Chan Shady Chan - 1 year ago 96
AngularJS Question

Firebase working with list data

"groups": {

"techpioneers": {

"name": "Historical Tech Pioneers",

"members": {
"alovelace": true,
"ghopper": true,
"eclarke": true


This kind of structure is found in firebase docs but I can't figure out how to do the "members" child. How to write the 'wildcard' username as the key and boolean as the value?

Sam Sam
Answer Source

You actually just write the boolean value (or the username object) to the database. The needed child nodes are created, when you add the first child.

For example:

firebase.database().ref('groups/techpioneers/members' + username).set(true);


firebase.database().ref('groups/techpioneers/members').set({username: true});
Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download