1

Here is my Firebase database, I want to get the object keys as a list:

var mydb = DatabaseRef.ref("projects").orderByKey();
        $scope.mylist= $firebaseArray(mydb);
        var data = $scope.mylist;

How can I get the keys of the object of data as array list?

1 Answer 1

1

You can use Object.keys in this scenario.

It will return an array of strings that represents the properties of the object (keys).

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.