Emoji Kitchen, the Force-Directed Graph | Forrest O. | Observable
ojs
ojs
ojs
ojs
ojs
ojs
ojs
ojs
ojs
ojs
Author
Forrest O.
@forresto
open web tools for creativity and community
Comments (2)
Fabian Iwand
May 26, 2022
You can use selection.filter() to simplify your logic: ~~~ .filter(d => d.collection === "native" && emojiKitchen.hasOwnProperty(
d.id
)) .style("cursor", "pointer") .on("click", (e, d) => { mutable graph = idToGraph(
d.id
); }); ~~~
Forrest O.
May 30, 2022
Nice!
Reply
Add comment
Subscribe to notifications
© 2026 Observable, Inc.
Terms of service
Privacy policy
Product
About
Pricing
Documentation
Release notes
Contact us
Open source
Notebook Kit
Plot
D3
Community
Explore
Forum
Bluesky
YouTube
X
9
Follow
Follow
Emoji Kitchen, the Force-Directed Graph | Forrest O. | Observable