React store mock data

In the React store SDK, you can create your own custom mock data for store development.

Running react store in mock mode

Run the React store application in development mode using mock REST services data by running npm run mock command. This command will start the React application with the default Emerald store.

To start with a different store such as Sapphire, use the following command.
npm run mock -- --appName <storeName>

The React store application uses the mockserver npm library. Upon running the above command, by default the mock server will be started on port 9002 pointing to the mocks folder for providing mock responses. For more details, see tools/mockServer.js file.

For more information about mockserver, see the link mockserver documentation and github-mockserver documentation.