Skip to content

Commit b8d0f67

Browse files
authored
Merge pull request #2668 from appirio-tech/revert-2666-dev
Revert "Production Release 2.4.7"
2 parents ce6c2f5 + 8e90711 commit b8d0f67

File tree

173 files changed

+13064
-18410
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

173 files changed

+13064
-18410
lines changed

.nvmrc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
8
1+
5

README.md

Lines changed: 41 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -1,32 +1,6 @@
1-
# Topcoder Connect App
1+
#### For folks working on this code base, we're organizing coding style and general guidelines [here](https://github.com/appirio-tech/connect-app/wiki/Community-Work-Read-Me-First!).
22

3-
Topcoder Connect is client facing application of Topcoder. Customers use Topcoder Connect to input requirements of their projects, then managers and
4-
copilots take it from there.
5-
6-
## Requirements
7-
8-
- Node.js 8+
9-
- Npm 5+
10-
11-
## Run locally for development
12-
13-
Prior to running the application locally you should add into your `/etc/hosts` the line `127.0.0.1 local.topcoder-dev.com`.
14-
15-
- `$ npm install` - Installs all dependencies.
16-
- `$ npm start` - Run application in development mode against Topcoder development environment using [dev](https://github.com/appirio-tech/connect-app/blob/dev/config/constants/dev.js) config. In this case the frontend is build in memory by webpack server and uses dev tools like redux-logger.
17-
18-
Open browser with URL http://local.topcoder-dev.com:3000.
19-
20-
## NPM commands
21-
22-
- `$ npm start` - Run application in development mode against Topcoder development environment. In this case the frontend is build in memory by webpack server and uses dev tools like redux-logger.
23-
- `$ npm build` - Create build for production in `/dest` folder. In this case built app is configured to run against Topcoder production environment using [prod](https://github.com/appirio-tech/connect-app/blob/dev/config/constants/master.js) config. Files are being minimized and `gzipped`.
24-
- `$ npm run lint` - Check js code linting.
25-
- `$ npm run lint:fix` - Check js code linting and trying to fix errors automatically.
26-
- `$ npm run test` - Performs tests running. **Note** we don't really have tests, so we only keep this command run successfully.
27-
- `$ npm run test:watch` - Performs tests on files changes.
28-
29-
## TC Deployment Notes
3+
# TC Deployment Notes
304
_[TC Deployment Notes should always be kept up to date **on the default branch**. Update these notes when changes to this information occur]_
315

326
**General Deployment:** This software is deployed to AWS S3 by CircleCI. It's ultimately delivered through AWS Cloudfront, which is fed from the S3 bucket. There are no EC2 systems involved in the delivery (althought Connect is fed from various micro-services).
@@ -44,12 +18,47 @@ _[TC Deployment Notes should always be kept up to date **on the default branch**
4418
* The _circle.yml_ file controls the build - see this file if you need to confirm if your commit will deploy anything
4519
* Circle-ci builds can be easily cancelled - please do so if you accidentally trigger an undesired build
4620

21+
# Customer-App
22+
23+
This repository houses new Customer pages, using React, Redux, and Webpack.
24+
25+
## Installation
26+
27+
We use node 8.9.x and npm 6.x, so you may need to download a new version of node. The easiest way is to download [nvm](https://github.com/creationix/nvm). We have a `.nvmrc` file in the root of the project, so you can just run `nvm use` to switch to the correct version of node.
28+
29+
Install dependencies by running the following in the root of the project:
30+
- `npm i`
31+
- **Note:** You must use npm 6.x. Type `npm -v` to ensure you have the correct version.
32+
33+
## NPM Commands
34+
- To run locally, run `npm start` and head to `http://localhost:3000/new_project`
35+
- Run tests with `npm test` or use `npm run test:watch` to rerun tests after files change
36+
- To make sure your code passes linting: `npm run lint`
37+
- To create the build: `npm run build`
38+
39+
## Login
40+
41+
During login, if your see `Invalid URL: http://localhost:3000` error in browser console, just browse http://localhost:3000 and it will show up.
42+
43+
Or, you can add into your `/etc/hosts` the line `127.0.0.1 local.topcoder-dev.com`. And access the app with http://local.topcoder-dev.com:3000. It will prevent you from getting `Invalid URL: http://localhost:3000` and you will be redirected successfully after login.
44+
4745
## Contributing
4846

4947
### Pull Requests
5048

5149
To contribute to the repository, please create a feature branch off of the dev branch. Once you're finished working on the feature, make a pull request to merge it into dev. Please make sure that every pull request has passed the build checks, which appear just before the "Merge pull request" button in github.
5250

51+
### Updating npm-shrinkwrap.json
52+
53+
General workflow to update `npm-shrinkwrap.json` would be:
54+
55+
- `npm install --no-optional` - with old npm-shrinkwrap (--no-optional to skip fsevents)
56+
- update `package.json` if you need to remove/update/add any packages
57+
- remove `npm-shrinkwrap.json`
58+
- `npm install --no-optional` with new `package.json`
59+
- `npm shrinkwrap` - to convert `package-lock.json` to `npm-shrinkwrap.json`
60+
- the new `npm-shrinkwrap.json` will have just the minimal diff
61+
5362
### Code Style
5463

5564
***Checkout the code and comments in `src/components/ExampleComponent` for an example React component, `.scss` file, and tests.***
@@ -98,12 +107,12 @@ SCSS Files
98107
}
99108
}
100109
SVG Icons
101-
- This repository uses plugin babel-plugin-inline-react-svg
110+
- This repository uses plugin babel-plugin-inline-react-svg
102111
- The plugin is used to inline-embed svg icons inside the markup
103-
112+
104113
Steps to adding new icons
105-
- Insert the svg file in the ~/src/assets/images/ directory
106-
- Add a new icon component file in directory ~/src/components/Icons/Icon-Name.jsx and reference it on the global
114+
- Insert the svg file in the ~/src/assets/images/ directory
115+
- Add a new icon component file in directory ~/src/components/Icons/Icon-Name.jsx and reference it on the global
107116
icon component in the ~/src/components/icons/ directory
108117
- Wrap the svg icon inside an object for caching to optimize on perfomance.
109118
```

config/babel/webpack.js

Lines changed: 0 additions & 40 deletions
This file was deleted.

config/constants/dev.js

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,5 @@ module.exports = {
4646
TC_NOTIFICATION_URL: 'https://api.topcoder-dev.com/v5/notifications',
4747
CONNECT_MESSAGE_API_URL: 'https://api.topcoder-dev.com/v5',
4848
TC_SYSTEM_USERID: process.env.DEV_TC_SYSTEM_USERID,
49-
MAINTENANCE_MODE: process.env.DEV_MAINTENANCE_MODE,
50-
51-
RESET_PASSWORD_URL: 'https://accounts.topcoder-dev.com/connect/reset-password'
49+
MAINTENANCE_MODE: process.env.DEV_MAINTENANCE_MODE
5250
}

config/constants/master.js

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,5 @@ module.exports = {
4646
TC_NOTIFICATION_URL: 'https://api.topcoder.com/v5/notifications',
4747
CONNECT_MESSAGE_API_URL: 'https://api.topcoder.com/v5',
4848
TC_SYSTEM_USERID: process.env.PROD_TC_SYSTEM_USERID,
49-
MAINTENANCE_MODE: process.env.PROD_MAINTENANCE_MODE,
50-
51-
RESET_PASSWORD_URL: 'https://accounts.topcoder.com/connect/reset-password'
49+
MAINTENANCE_MODE: process.env.PROD_MAINTENANCE_MODE
5250
}

config/webpack/common-modifications.js

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,6 @@
44
* webpack merge.
55
*/
66

7-
const path = require('path')
8-
const dirname = path.resolve(__dirname, '../..')
9-
107
module.exports = function (config) {
118
/*
129
Exclude some folders from babel-loader
@@ -18,10 +15,9 @@ module.exports = function (config) {
1815
]
1916

2017
/*
21-
Use Connect App preset file for babel config
22-
It may contain some modifications of babel config which comes from `topcoder-react-utils`
23-
*/
24-
jsxRule.options.presets = [path.resolve(dirname, './config/babel/webpack.js')]
18+
Add babel-plugin-lodash to exclude full lodash lib and include only necessary methods
19+
*/
20+
jsxRule.options.plugins = (jsxRule.options.plugins || []).concat(['lodash'])
2521

2622
/*
2723
Include packages `appirio-tech-react-components` and `tc-ui`

0 commit comments

Comments
 (0)