~/talk

Load Data using GraphQL Queries in a Gatsby Component with StaticQuery

Talkat apidays New York 2020 · 2020-07-28..07-29· [javascript, web-platform]
links:none on file
slides:none on file

Builds a small Gatsby starter site and proves a component can fetch build-time data itself using a GraphQL query rather than relying on a page query. Uses Node.js + Gatsby, a local siteMetadata JSON file as the data source, React components and the Gatsby StaticQuery (or its hook) to inject the title into a header. One simple GraphQL query returns the title and the page renders it successfully, demo runs end-to-end.

AI-written summary · about

  1. 0:00Start
  2. 2:54Gatsby and Graphql
  3. 5:04What Is Gatsby
  4. 22:17Building a Brand New Gatsby Website
  5. 23:30Add a React Header
  6. 28:32Import Graphql
  7. 31:06Static Queries
  8. 31:51The Static Query Hook
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.