is there a way to set default values in
is there a way to set default values in the schema without using literals?
e.g. i want set a boolean field to false by default
3 Replies
The general approach is:
- Make a single helper function (not a Convex function) that is responsible for committing inserts to the table in question (I have one for all my tables)
- In that function, set the value of the field to false if no value is provided
Ah I see someone already responded with this
may i see your function, or like a simplified version of it pls
Something like: