Default option in checkbox supported?

The default option seems to work for me in the checkbox field blueprint:

    label: "Show link?"
    type: checkbox
    text: "show link"
    width: 1/2
    default: true

Should this page be updated to show it? Or is it an unsupported feature.

Hm, seems like that works by accident. :smiley:
I can’t find any code in the checkbox field specifically that uses the default option.

I have created an issue on GitHub about this, maybe Bastian knows more about the intention behind this. If it’s indeed not a feature, I think we should make it an official one with proper code for it.

You can also use default: 1 instead of default: true or default: 0 to have the box unchecked by default. The default option is inherited from the base field.

1 Like