1 | © 2019 GoodData Corporation
|
2 |
|
3 | # GoodData Create React App
|
4 |
|
5 | This is a CLI tool that creates a new React project with a proxy set up to connect to your projects on the GoodData platform.
|
6 | The new app features some widgets and helpers that could come in handy.
|
7 | This is built on top of Create React App. For more info see [Create React App documentation](https://facebook.github.io/create-react-app/).
|
8 |
|
9 | ## How to use
|
10 |
|
11 | To create a project called `my-app`, run this in your terminal:
|
12 |
|
13 | ```bash
|
14 | npx @gooddata/create-gooddata-react-app my-app
|
15 | ```
|
16 |
|
17 | or if you prefer Yarn:
|
18 |
|
19 | ```bash
|
20 | yarn global add @gooddata/create-gooddata-react-app
|
21 | create-gooddata-react-app my-app
|
22 | ```
|
23 |
|
24 | Then follow the instructions provided by the CLI.
|
25 |
|
26 | ## CLI docs
|
27 |
|
28 | The CLI tool supports several flags:
|
29 |
|
30 | - `-d, --domainUrl <domain>` URL of your GoodData domain
|
31 | - `-p, --projectId <projectId>` projectID of your GoodData project
|
32 | - `-c, --config <config>` path to configuration file (see below)
|
33 | - `--no-install` skip yarn installing the app dependencies
|
34 | - `--verbose` output additional logs, useful mainly for debugging and bug reports
|
35 | - `-h, --help` output usage information
|
36 |
|
37 | ### Configuration file
|
38 |
|
39 | The configuration file has the following structure:
|
40 |
|
41 | ```json
|
42 | {
|
43 | "domain": "(Required) domain where the project is hosted, e.g. https://developer.na.gooddata.com",
|
44 | "projectId": "(Required) the projectId of the project (must be hosted on the domain specified above)",
|
45 | "appName": "(Optional) name of the app to use"
|
46 | }
|
47 | ```
|