Skip to content

Instantly share code, notes, and snippets.

@dustingetz
Last active February 25, 2023 23:41
Show Gist options
  • Star 2 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dustingetz/dd67a35d818e3a1bf6733147cf5cdea7 to your computer and use it in GitHub Desktop.
Save dustingetz/dd67a35d818e3a1bf6733147cf5cdea7 to your computer and use it in GitHub Desktop.
Electric virtual scroll over node_modules v2

virtual scroll over node_modules v2 — Electric Clojure

  • Direct filesystem reads from the view
  • Direct function composition in the style of PHP, despite network
  • No API, no client side database, no frontend state at all (except DOM), no frontend/backend.
  • Literally all accidental complexity GONE
  • 100% of server data sync is managed by Electric
  • Rows have arbitrary server local data access, here querying file metadata #clojure
  • Optimized and no scroll jank – DOM elements are fixed in place and reused
  • Demo assumes static height to snap the scroll cleanly to rows like a google sheet.
  • source code: demo_explorer.cljc
20220908.grid.scroll.node.modules.-.no.jank.mp4
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment