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
Copy file name to clipboardExpand all lines: README.md
+17-9Lines changed: 17 additions & 9 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -8,9 +8,10 @@ Please add any missing content to this readme.
8
8
9
9
## Development Environment Quick Start
10
10
11
-
We support both front end and backend development in this repository currently. Depending on which part of the admin panel you are contributing too, you have different options for setting up development.
11
+
We support both front end and backend development in this repository currently. Depending on which part of the admin panel you are contributing too, you have different options for setting up development.
12
12
13
13
There are three options for setting up your development environment:
14
+
14
15
1. For frontend work only
15
16
1. Skip installing and running the API locally
16
17
2. For backend work only
@@ -30,7 +31,8 @@ See https://git-scm.com/downloads for instructions.
30
31
_Node.js version 12.x works best for now; later versions have exhibited some strange behaviour with this project.
31
32
If you encounter issues with the server, check your version of Node.js first. This includes CORS related issues when fetching the API._
32
33
33
-
We recommend using [nvm](https://github.com/nvm-sh/nvm) to install and manage your Node.js instances. More details here: https://www.sitepoint.com/quick-tip-multiple-versions-node-nvm/
34
+
We recommend using [nvm](https://github.com/nvm-sh/nvm) to install and manage your Node.js instances. More details here: https://www.sitepoint.com/quick-tip-multiple-versions-node-nvm/
@@ -61,6 +64,7 @@ _Only required for backend/API development_
61
64
1. Get the server dev env file pinned to the #admin_panel_chat channel in Greenstand Slack: `.env.development` (Note that the leading `.` may be removed if you download the file from Slack, so you'll need to rename it)
62
65
1. Copy the file to the `./server` directory within your local repo
63
66
1. Add a `.env.local` file in the `./client` directory containing the following line:
67
+
64
68
```
65
69
REACT_APP_API_ROOT=http://localhost:3000
66
70
```
@@ -94,19 +98,24 @@ npm start
94
98
We use automatic semantic versioning, which looks at commit messages to determine how to increment the version number for deployment.
95
99
96
100
Your commit messages will need to follow the [Conventional Commits](https://www.conventionalcommits.org/) format, for example:
101
+
97
102
```
98
103
feat: add new button
99
104
```
105
+
100
106
Since we squash commits on merging PRs into `master`, this applies to PR titles as well.
101
107
102
108
## Keeping Your Fork in Sync
103
109
104
110
Your forked repo won't automatically stay in sync with Greenstand, so you'll need to occassionally sync manually (typically before starting work on a new feature).
111
+
105
112
```
106
113
git pull upstream master --rebase
107
114
git push origin master
108
115
```
116
+
109
117
You might also need to sync and merge `master` into your feature branch before submitting a PR to resolve any conflicts.
118
+
110
119
```
111
120
git checkout <feature_branch>
112
121
git merge master
@@ -206,8 +215,6 @@ Here is our [wiki page for troubleshooting](https://github.com/Greenstand/treetr
206
215
207
216
Help us to improve it by adding your experience solving this problem.
208
217
209
-
210
-
211
218
#### View the Treetracker Admin Panel
212
219
213
220
Visit http://localhost:3001
@@ -317,6 +324,8 @@ Redux-connected component, and how to test it.
317
324
318
325
## Code style guide
319
326
327
+
If you are using VSCode as your IDE, please follow [this guide](https://www.digitalocean.com/community/tutorials/how-to-format-code-with-prettier-in-visual-studio-code) to setup Prettier and automatically format your code on file save. Configuration files are already included in this repo.
328
+
320
329
**Indention** 2 Spaces for indentation
321
330
322
331
**Semicolon** Use semicolons at the end of each line
@@ -329,15 +338,15 @@ Redux-connected component, and how to test it.
329
338
constfoo='bar';
330
339
```
331
340
332
-
**Braces** Opening braces go on the same line as the statment
341
+
**Braces** Opening braces go on the same line as the statement
333
342
334
343
```js
335
344
if (true) {
336
345
console.log('here');
337
346
}
338
347
```
339
348
340
-
**Variable declaration** Declare one Varable per statment
349
+
**Variable declaration** Declare one Variable per statement
**Descriptive conditions** Make sure to to have a descriptive name that tells the use and meaning of the code
372
+
**Descriptive conditions** Make sure to have a descriptive name that tells the use and meaning of the code
364
373
365
374
```js
366
375
constisValidPassword=
@@ -419,7 +428,6 @@ In this way, we can write the code and get the tests result immediately.
419
428
420
429
NOTE: when running tests, the files related to Loopback are loaded from ./dist folder. That's because for Jest, it does not output compiled files at all, and Loopback will try to load the controllers at runtime.
421
430
422
-
423
431
### See [Current Milestone](https://github.com/Greenstand/treetracker-admin/issues?q=is%3Aopen+is%3Aissue+milestone%3A1.1.0)
424
432
425
433
See [Contributing to The Cause](https://github.com/Greenstand/Development-Overview#contributing-to-the-cause)
0 commit comments