Our great sponsors
-
SurveyJS
Open-Source JSON Form Builder to Create Dynamic Forms Right in Your App. With SurveyJS form UI libraries, you can build and style forms in a fully-integrated drag & drop form builder, render them in your JS app, and store form submission data in any backend, inc. PHP, ASP.NET Core, and Node.js.
A longer answer would be yes it is ok BUT what you are doing is coming up with a Domain Specific Language (DSL) for building forms which can be an undertaking both to author and to communicate with other developers. I would suggest using React and javascript to manage the fields if possible and if not look into a library that takes on the task of making a DSL and provides documentation for it (to help communicate to other developers). I found this after a quick search https://data-driven-forms.org/