-
Notifications
You must be signed in to change notification settings - Fork 211
Several updates #163
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Several updates #163
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…istings Fixes #155 Also includes some unrelated ESLint fixes
Fixes #158 Also sets correct group ID for Veterans community
- The setup has been enhanced to support containers in the splitted code during server-side rendering; - Dashboard and Challenge Details pages has been splitted into separate code chunks. It works fine, and will work even better once their server-side rendering is enhanced.
The code-splitting setup is not finished yet (misses HMR of CSS code), but it has no impact on the remote deployments (technically, they both use production code, launched against dev / prod Topcoder backends); thus, rolling this out to remote dev, to test how this setup will perform in real life.
- Production build: changes generated stylenames to just [hash:base64:6], which makes both CSS and JS files about twice smaller, comparing to previous verbose class names; - Development build: keeps verbose class names, for convenience of any debugging ([path]___[name]___[local]); - Test rendering: keeps the old class names to avoid a massive update of test snapshots ([path]___[name]__[local]___[hash:base64:5] - this is also default for "babel-plugin-react-css-modules").
It significantly speeds-up HMR. Trade-off is that browser's dev tools become extremely slow, due to large size of CSS code (~5mb) (it is a way larger than in prod, because generated classnames are longer, and some dublicates of the code are not cleaned out). However, right now ~4.5mb of CSS is the size of the main CSS bundle. In the next commits, the new approach for code-splitting will be implemented on all existing routes, and the size of the main CSS bundle will become a way smaller. Presumably, even in dev, without CSS optimizations, regular pages won't have more than ~1mb of CSS code; thus, hopefully, browser's dev tools will work fast again.
The code of plugin has been updated to accept "justExtract" option, which tells the plugin just to extract CSS and to avoid doing any other staff we do not need. Temporarly serving updated plugin from my own fork, will be switched to the npm version as soon as the change is merged in and published.
Code-splitting implemented for all routes related to the main Topcoder website. Also related routing has been refactored in the process, and become a way cleaner.
+ cleaning up of the related routing code.
Submission #518429 by ouyangki to the challenge http://www.topcoder.com/challenge-details/30058704/?type=develop
Fixes #145 Makes Challenge Forum tab header to work as link to the forums
- Now direct links to the new challenge details page got rendered very fast; - Loading indicator is now consistent between the page loading (i.e. loading of the related code chunks) and loading challenge details into the page; Server-side rendering may be further enchanced (at the moment, challenge results are not injected at the server side).
Prior to this point, most of the community-related logic (loading of meta-data, auth checks, loading of other data, and connection of all community components to Redux) was handled by /src/shared/containers/tc-communities/Page/index.jsx. It was a big module with a messy logic and some performance issues, which had to be refactored into something more maintainable. In this commit the meta-data loading and auth checks logic have been split into a separate Loader container, and it is ensured that it works optimally (does not reload any data when not-necessary).
The standard Community Header and Footer logic is moved to dedicated containers.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
No description provided.