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

关于Firebase有些疑问 #42

Open
daiweixiong opened this issue Jul 25, 2016 · 1 comment
Open

关于Firebase有些疑问 #42

daiweixiong opened this issue Jul 25, 2016 · 1 comment

Comments

@daiweixiong
Copy link

Firebase 的api资料有推荐的吗?这个demo里面有关firebae部分的代码没看懂,如:api.child().on(),api.child().once(),找了很久没找到firebase的api资料。
不知道这里面的items 数据怎么从firebase上下载下来的。
api.child('topstories').on('value', snapshot => {
topStoryIds = snapshot.val()
debugger;
store.emit('topstories-updated')
})

api.child('item/' + id).once('value', snapshot => {
const story = itemsCache[id] = snapshot.val()
resolve(story)
}, reject)

@felbry
Copy link

felbry commented Sep 28, 2016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants