MCPcopy Create free account
hub / github.com/firebase/quickstart-js / onStarClicked

Function onStarClicked

database/scripts/main.ts:317–322  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

315
316 // Bind starring action.
317 const onStarClicked = function () {
318 const globalPostRef = ref(database, '/posts/' + postId);
319 const userPostRef = ref(database, '/user-posts/' + authorId + '/' + postId);
320 toggleStar(globalPostRef, uid);
321 toggleStar(userPostRef, uid);
322 };
323 unStar.onclick = onStarClicked;
324 star.onclick = onStarClicked;
325

Callers

nothing calls this directly

Calls 1

toggleStarFunction · 0.85

Tested by

no test coverage detected