npx create-react-app demo-app --template=typescript
cd demo-app
The KOS Model Framework and UI SDK assumes that Consumer UI (CUI) and Non-Consumer UIs ( NCUI) will be built with React in order to best utilize the model framework and its associated hooks.
The following will guide you through the steps to create a new React UI Project that can hold KOS models and utilize the KOS Model Framework.
Create a new UI Project demo-app using create-react-app. Make sure to use the Typescript template as it is required for the SDK annotations to function properly:
npx create-react-app demo-app --template=typescript
cd demo-app
The KOS UI SDK can be installed along with its dependencies by importing
the @coca-cola/kos-ui-components
module into your project:
npm install @coca-cola/kos-ui-components@canary
At this point, your UI project is now configured to start using the KOS Model Framework
If you start the application you should see the standard create-react-app startup screen.
npm start
The following should be visible in the browser: