nigelgilbert / localgraf-demo-design-docs

Design docs & proposal for Arc + LocalGraf demo

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

LocalGraf + Arc Demo Design Spec

Objective

  • Implement a "recent events" page and an "event" page to demo Arc + LocalGraph
  • Build something as production ready as possible to scout Arc development & future integrations

Context

Challenges

  • Resolver API is opaque and poorly documented
  • LocalGraf API may change (given future requirements)
  • Designs & markup will change

Demo Implications

"Recent Events" widget is unaffected (static "fetch recent" query doesn't rely on resolver).

Event Pages will be probably be generated with Resolvers in production (e.g. an Arc Template housing our React components + a Content Source that queries LocalGraf for an Event). We won't know how to implement Resolvers until Arc training.

We can't make an event and imediately go to /demo/event/<id> to see it. To demo a new event we have to create a new Page in PageBuilder Page using a Custom Field and specifying an event_id in this PageBuilder Page Editor menu:

Demo Proposal

  1. Add event in Arc admin
  2. Show the "Recent Events"
  3. Create a new Arc Page
    • select Event by event_id in PageBuilder
    • refresh
    • new Event Page will now be rendered

Implementation Notes

  • If we implement a LocalGraf Content Source that works in the PageBuilder GUI drag-n-drop, then it'll be trivial to plug into a Resolver later
  • data fetching / error handling will occur in a parent container component
  • markup / designs will go in pure functional child components
    • max code reuse (markup is separated from logic and can be swapped out later)

Other Notes

About

Design docs & proposal for Arc + LocalGraf demo