AI Content Chat (Beta) logo

Appendix B SAmple Code User Interface You can use any one of the following UI scripting library or UI scripting frameworks to develop the UI of the application along with its supporting CSS framework: • Angular • Native Script • React Native • React • Electron • Vue We have chosen the Angular framework for this example because it’s based on MVC architecture, whereas React’s JavaScript library just helps us to update the view of the user. But you can integrate FLUX to control the workflow of React-based UI application. You can choose one of the previously listed frameworks or libraries depending upon your requirements, design and implementation of which will be suitable for your application. Points to evaluate before choosing a UI technology stack are: • MVC: MVC pattern has three components: model, view, and controller. • Model is bound with view as well as controller. • View is a user interface that binds the model with the Document Object Model (DOM) and display data to the user and also enables the user to modify the model. • Controllers are responsible for controlling the flow of the application; if you make a web services request the controller is responsible for providing a response back to the application. The MVC pattern provides control over business logic implemented on UI scripting; hence you should consider whether your application needs the MVC pattern. • Data binding: Data binding would help you to establish a relationship between your business logic with the DOM. Angular has two-way binding, whereas React has one-way binding. 334

Building Digital Experience Platforms - Page 344 Building Digital Experience Platforms Page 343 Page 345