Pricing Blog

Set default value for Attributes

  • matt_apollodev-1415375300212166686

    Matthieu B.

    3 days ago

    i'm trying to set a default value for my component's attributes.
    Ideally for the input type, i'd like to have a select, or object where I can just select the input type instead of having to type it.

    How could I do that ?

    Thanks a lot for your help
    1415375300891508829-image.png
  • lucasg-1415392903970164859

    Lucas G

    3 days ago

    There's no types support for component attributes yet
  • So you'll have to type in the input type for the time being
  • If you want it to default to text for example, use a Default to node within the component in the HTML attribute for the input
    🔥1
  • And make sure they are lowercase
  • jaycmpb-1415393673918808277

    Jay Campbell

    3 days ago

    🔥3
  • matt_apollodev-1415403088289988769

    Matthieu B.

    3 days ago

    Lovely guys.
    That is premium support, thank you 🙏