PricingBlog

context availability?

  • rscott-1199440859725307945

    Bishop

    1 year ago

    Just checking in on this, someone mentioned Contexts are not available yet, but I see something in the interface and I think its not working

    I am trying to access a workflow from main in a component, it doesn't show up anywhere after setting this, tho.
    1199440860006330490-Screenshot_2024-01-23_at_1.47.57_PM.png
  • andreasmoller-1199441032853606400

    Andreas Møller

    1 year ago

    You have to export it from the main component first.
  • rscott-1199442945737236581

    Bishop

    1 year ago

    I see that there's already a tutorial. You guys are so great.
  • andreasmoller-1199443038980804711

    Andreas Møller

    1 year ago

    👍
  • rscott-1199443392174759997

    Bishop

    1 year ago

    It seems like this is useful for calling /auth/me so that you can share the data to other components so those components don't need to duplicate and then hit the API to the backend all by themselves does that sound right? If they need the user_id for example, they can just get it out of the main page context

    Does that sound right?
  • rscott-1199443891687014453

    Bishop

    1 year ago

    i guess i could use attributes for that as well, come to think of it. its a simple example probably not the best way to use context
  • andreasmoller-1199458571520311541

    Andreas Møller

    1 year ago

    Yes 100%. but It is generally most useful if you have complex pages with a lot of nested components.
    If you just have 1 layer then you can just pass the same data with attributes.