Framework-independent function API
USoft provides a function API for creating controls that are portable across supported frameworks.
Why would you need this?
Creating a button directly out of a HTML string does not automatically style it the same way as a button generated by a button control in a framework you are using, nor will it always behave the same way. Of course, adding the appropriate classes and event types would solve that, but when changing to a different framework you will have to change all these class names and even types. Moreover, some frameworks behave completely differently than others, with different HTML elements that are needed, and even different framework-specific events.
The syntax and API for framework-independent functions is identical for each of the frameworks supported: the function body takes care of the differences. The implementation is such that each of these functions, when called, calls another function that is specific for the framework.
For details on supported frameworks, search 'frameworks' on USoft Community or click here.
The examples displayed in the table below happen to make use of the ‘bootstrap4’ framework.