Build forms with AI? In the past, whenever I built long forms, I'd first create a JSON schema to ...Build forms with AI? In the past, whenever I built long forms, I'd first create a JSON schema to ...
The network for creativity
Join 1.25M professional creatives like you
Connect with clients, get discovered, and run your business 100% commission-free
Creatives on Contra have earned over $150M and we are just getting started
Build forms with AI?
In the past, whenever I built long forms, I'd first create a JSON schema to represent the form, then dynamically render it in React.
This made adding or removing fields as simple as adding or removing a JSON block, without touching JSX. Also you can store the json schema in a database for later manipulations if needed
The downside is that the components are pre-styled, so there's less flexibility over the UI. But honestly, who cares? Most forms don't need a complex interface. Just a bit of branding with logos and colors (like google and microsoft forms)
The real complexity comes when you introduce conditionals, calculated fields, branching, and other form logic.
For this side project, I'm experimenting with using an LLM to generate the schema, while a custom React renderer handles layouts, subsections, conditionals, calculated fields, and more.
I have no idea where this is going, but just getting to think through the architecture excites me.
I'll be building it in public (or abandoned it when i get bored) 
Back to feed
The network for creativity
Join 1.25M professional creatives like you
Connect with clients, get discovered, and run your business 100% commission-free
Creatives on Contra have earned over $150M and we are just getting started