PricingBlog

Component api data

  • samuelt_19895-1277311856406560849

    Samuel T

    1 year ago

    I had a navbar on one page which showed api data (user first name and last name)
    And I converted it into a component, but now the api data only shows on the component page, and not any other page the component is one - instead it just displays "null"
  • Tod-1277311858272895138

    Tod

    1 year ago

    Great energy @Samuel T! Your continuous contribution to the toddle Community just made you advance to Community Level 3!
  • tomthebigtree-1277314121213153372

    Tom Ireland

    1 year ago

    Hey. When working with data in components, it removes it from the page level, however if you need this on the page level you can use events to send this back to the page. Take a look at https://docs.nordcraft.com and let us know if you need any more help with that.

    If the API should be on the page, you'd need to define it there and then use attributes to pass the data into the component. See https://docs.nordcraft.com
  • samuelt_19895-1277391361137573908

    Samuel T

    1 year ago

    Thanks so much @Tom Ireland 🙏
    👍1