You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This service was generated with Amplication. It serves as the client-side for the generated server component. The client-side consist of a React application with ready-made forms for creating and editing the different data models of the application. It is pre-conffigured to work with the server and comes with the boilerplate and foundation for the client - i.e., routing, navigation, authentication, permissions, menu, breadcrumbs, error handling and much more. Additional information about the admin component and the architecture around it, can be found on the [documentation](https://docs.amplication.com/guides/getting-started) site. This side of the generated project was bootstrapped with [create-react-app](https://github.com/facebook/create-react-app) and built with [react-admin](https://marmelab.com/react-admin/).
Configuration for the client component can be provided through the use of environment variables. These can be passed to the application via the use of the `.env` file in the base directory of the generated service. Below a table can be found which show the different variables that can be passed. These values are provided default values after generation, change them to the desired values.
| PORT | the port on which to run the client | 3001 |
25
+
| REACT_APP_SERVER_URL | the url on which the server component is running |http://localhost:[server-port]|
26
+
27
+
> **Note**
28
+
> Amplication generates default values and stores them under the .env file. It is advised to use some form of secrets manager/vault solution when using in production.
29
+
30
+
31
+
## Step 2: Scripts
32
+
33
+
After configuration of the client the next step would be to run the application. Before running the client side of the component, make sure that the different pre-requisites are met - i.e., npm, docker. Make sure that the server-side of the application is running.
34
+
35
+
```sh
36
+
# installation of the dependencies
37
+
$ npm install
38
+
39
+
# starts the application in development mode - available by default under http://localhost:3001 with a pre-configured user with the username "admin" and password "admin"
40
+
$ npm run start
41
+
42
+
# builds the application in production mode - available under 'build'
43
+
$ npm run build
44
+
45
+
# removes the single build dependency from the project
0 commit comments