This is a Retrospective Idea board, powering retrospected.com.
Β
Β
This project is both an actual product, and also a technology demo using the latest and greatest JavaScript/TypeScript libraries of the month.
It features the following technologies:
- React 16
- React Hooks
- React Router 4
- Mono Repo / Yarn Workspaces
- TypeScript
- Hot-reloading
- Socket IO
- Webpack 4 (See older versions for Webpack 1, 2 and 3)
- Material UI design
- Styled Components
- Multilingual / Internationalization
- Postgres (optional), defaults to NeDB (in-process)
- Jest for Unit Testing
- React Testing Library, for Integration Tests
- Yarn, replacing NPM
- Docker, for easy deployment
- Kubernetes, to scale Retrospected for its 10M+ users (not)
- Travis, for Continuous Integration and Deployment (CI/CD)
Previous versions, up to v1.0.1 featured the following libraries:
ReduxCSS Modulesredux-sagareselectESLint for JS and JSX
Yarn
: Please install Yarn, as this mono-repo uses Yarn Workspaces which won't work with NPM.
- Clone this repository
- Switch to the
master
branch (the default isdevelop
which might not be stable:git checkout master
) yarn
to install the dependencies (notnpm i
!)yarn start
to transpile the server, run the server on port 8080 and start the UI- Open your browser on http://localhost:3000
Follow the steps in "How to run for development" below.
- Clone this repository
yarn
to install the dependencies (notnpm i
!)- Open another terminal (you need two of those, and the order is important)
yarn start-ui
on the first terminal to run live Webpack with hot-reloadyarn start-server
on the second terminal to start the backend- Open your browser on http://localhost:3000
You must have docker
and docker-compose
installed on your system.
- Copy
docker-compose.yml.example
todocker-compose.yml
- Run
docker-compose up -d
- VoilΓ !
This will run a production-ready version of Retrospected automatically, using Postgres. You don't need to have anything installed other than Docker. This will install and run:
- Postgres
- pgAdmin4 (Web UI for postgres)
- The Retrospected Nodejs backend
- The frontend, served by
nginx
.
When using the Docker deployment, your database runs from a container. But if you still need to make some backup of your data, you can do the following:
- Get the docker database image ID by doing:
docker ps
- Run
docker exec -t <docker_image_id> pg_dumpall -c -U postgres > dump_`date +%d-%m-%Y"_"%H_%M\_%S`.sql
- To restore your databases:
cat dump_1234.sql | docker exec -i <docker_image_id> psql -U postgres
- Clone this repository
yarn
to install the dependencies (notnpm i
!)npm test
to run the tests- or
yarn test-watch
to run the tests every time you change a file
By default, the database engine is NeDB, an in-process database with no external dependencies (i.e. no database to install on your system).
If you want to use a more "production-ready" database such as Postgres (without Docker), copy .env.example
to .env
, change DB_TYPE
to postgres
and fill the rest.
To know more about Kubernetes, see the readme file in the k8s
folder.
- Run both client and server normally (
yarn start-server
andyarn start-ui
) - From the browser window where the website is open, open the Chrome Dev tools
- Go on the Sources tab, and on the left, find your sources under
webpack://
and then.
. - You can then put breakpoints in there and debugging
- Adding a real (but optional) login mechanism (Google/GitHub etc.)
- Highlight posts where the user voted
- Adding Sentry support for the backend
- Making Google Analytics and Sentry configurable at run-time (as in Docker run-time)
- Adding Copy to clipboard compatibility for more browsers
- Preventing the app from crashing when cookies are disabled on Firefox
- Handling disconnections better by not reconnecting automatically and displaying a message instead.
- Kubernetes configs. Deploy Retrospected to the cloud! βοΈ π βΈοΈ
- Making the backend scalable by making SocketIO use Redis to communicate between instances. This is disabled by default and is only useful for Kubernetes deployments.
- The backend hostname is now configurable on the nginx config on the frontend.
- Replaced all occurences of
withRouter
byuseHistory
anduseParams
- Added CI/CD support with Travis
- Auto-deployment of Docker images to Docker Hub
- Changing the UX related to Summary Mode
- Added the ability to copy the content of the session in the clipboard, both in Markdown format and Rich Text
- Added Error Boundaries to improve the user experience if the app crashes
- Added support for Sentry.io (error logging)
- Fixed an issue where multiline content was not displayed properly for anyone except the author
- Fixed an issue where a post couldn't be deleted if it had votes attached to it
- Issue 56 - Fixed an issue where new users who were not persisted yet couldn't vote (π Thanks @dkistner)
- π©πͺ German Translation (π Thanks @PaulBrandt)
- Bugfix: First post was sometimes not saved on regular sessions
- IE fix: the previous polyfill didn't quite work with IE9 to IE11.
- Older browser support (IE11, somewhat works with IE10 and IE9).
- Adding an "outdated browser" warning
- Adding a remaining votes counter when using a maximum number of votes rule.
- Changing how Editable Labels work: they now only fire onChange on blur or Enter, minimizing the amount of traffic over the socket
- Removing the REACT_APP_DEBUG environment variable (using NODE_ENV instead).
- Adding a loading spinner while loading the game now that we can't predict which number of columns are going to appear on screen.
- Making sure index.html is not cached by Nginx on production
- Removing .map files on production
- MS Windows support/fixes (π Thanks @srraf).
- PR-48 - Fixed a word-wrapping issue when we have only one (long) post (π Thanks @manicmaniac).
- Fixes a possible race-condition issue with "vote" syncing.
- Adding full customisation of columns and rules:
- You can now create a board with 1 to 5 columns
- You can allow a user to vote for his own posts
- You can allow multiple votes on the same post
- You can limit the number of up and down votes
- You can choose to display the name of the author, and the name of the persons who vote
- Your language selection is now remembered between sessions
- Various UI fixes:
- Login modal improvements
- Editable label improvements
- Various Docker improvements
- Upgraded dependencies
- π Special thanks to @jesusabp, @zalexki and @jfritz for their inputs and ideas!
- Upgraded dependencies
- Allows multi-line posts and comments (use the shift key to add a new line) (π Thanks @andyk314)
- Re-adding Hot Reload, which now works great with TypeScript and Create-React-App.
- Upgraded dependencies
- Fixed an issue with Docker eating too much space with its unlimited log size. Log is now limited to 50mb.
- Added an "Action" field on each Post: this allows the user to define a list of actions that need doing in the next sprint, and allows displaying this list in the Summary Mode.
- Bugfix: In certain conditions, some race-condition would store a post with a null session ID (so the post was lost forever).
- Bugfix: Disabled the Web Worker, as it's not working properly when loading a game directly (and not loading the homepage).
- Adding support for Postgres migrations
- Adding created/updated fields on Post and Session
- Bugfix: Summary mode wasn't ordered by votes anymore. (π Thanks @cindyccook)
- Complete rewrite
- TypeScript
- React Hooks
- @testing-library/react
- New component library (MaterialUI)
- Docker-friendly
- π―π΅ Japanese Translation (π Thanks @sat0yu)
- Simplified the ESLint configuration
- Introducing Prettier (
yarn format
) - Upgrading to Babel 7
- React 16
- Webpack 4 (for previous versions of webpack, see below)
- Using @bionikspoon/react-toolbox instead of the original
react-toolbox
, as the project is no longer maintained and doesn't work with React 16. - Upgraded all the other dependencies, everything should be up-to-date
- Improved the home screen
- Webpack 3 (for Webpack 2, look at version 0.9.0)
- Converting entire project to 2-space indentation
- Upgrade other dependencies
- π΅π± Polish Translation (π Thanks @olaf-cichocki)
- π¦πͺ Arabic Translation (π Thanks @Meshredded)
- Improved the loading screen
- Webpack 2 (for Webpack 1, look at version 0.8.1 and older)
- React 15.5 (which needs the new
prop-types
module, among other things) - React Router 4 (completely different way of doing the routing)
- Move the structure of the project to a modular structure
- Upgraded all the other dependencies to the latest versions, except
react-toolbox
- Hotfix (ESLint errors on production build)
- Using redux-saga-testing to test sagas
- π¨π³ Chinese (Traditional and Simplified) Translation (π Thanks @aqutw)
- Using Yarn
- Updating dependencies
- Fixing some Spanish translation mistakes (π Thanks @MrPolymath)
- Fixed a bug where the Vote buttons would allow a user to vote multiple times (on the UI only)
- Good test coverage, using Jest
- π·πΊ Russian Translation (π Thanks @vectart)
- πͺπΈ Spanish Translation (π Thanks @andresin87)
- Replacing PNG flags by SVG/CSS versions
- Using
react-hot-loader
3.0.0 (beta2) for Hot reloading - Fixing a few mobile/responsive issues
- React-toolbox 1.0.0
- Debugging instructions
- Added the ability to edit existing posts inline (posts you wrote)
- Adding a new Invite button to simplify and explain how to invite other people
- Removing the snackbar
- Removing ES7 decorators, as they are not standard yet
- Removing hash on CSS and JS on production (not necessary since we have the version number)
- Fixed a bug on the anti-spam when if using a proxy (nginx for instance), the wrong ip was used
- Fixed a bug where the linting would fail if the default configuration was used (π Thanks @veselignome)
- Full support of ESLint, based on AirBnB rules
- Adding an anti-spam for SocketIO, because someone is having fun crashing my server (thanks!)
- Adding the possibility to join a previously joined session quickly (π Thanks @Sonaryr)
- Performance improvement on title edit (Also thanks to @Sonaryr π)
- New Logo!
- Added Favicons
- Updated the screenshot on the readme
- package.json version updated properly this time
- Improved the "Create Session" page, allows a user to create a session with a custom name
- Ability to edit that session name in real-time (by anyone)
- Added a "Summary Mode": this gives a summary of a current session, allowing a user to copy-paste the entire content easily
- New shorter session IDs
- New look-and-feel (new colours)
- Using reselect to create memoized selectors
- Improving performance by using
shouldComponentUpdate
via a custom base Component - Updated to the brand new React 15
- Improving Windows support by allowing Windows users to use the same commands as *nix users
- π³π± Internationalisation: added Dutch to the list of supported languages (π Thanks @Sonaryr)
- Adding support for more robust databases (NeDB, by default, in process, and MongoDB)
- Change to the Like / Unlike logic: a user can now only vote once, and not for his own posts
- Change to the Like / Unlike logic: like and unlikes counts are separated
- Adding ES7 decorators, more readable than the previous curry-ed functions
- Better support for Windows
- π§π· Internationalisation: added Brazilian Portuguese to the list of supported languages (π Thanks @renancouto)
- Using
redux-saga
instead ofredux-thunk
- Persistence: Simple persistence to disk (no database needed)
- Support for Google Analytics (with precise events monitoring)
- Ability to logout, and to leave a session
- Improve the reliability of the clients list (currently connected users)
- Fix issues when the web fonts can't load (firewall blocking for example)
- π¬π§ π«π· ππΊ Internationalisation: support for English, French and Hungarian (π Thanks @iaretiga)
- Minor visual tweaks
- Better console logs, server side
- Big clean up of un-used files and old libs
- First production version
- Basic functionalities are there and working
- Login
- Creating a session
- Joining a session
- Adding new posts
- Like / Unlike posts
- Ability to delete our own posts
- List of connected users
- No persistence (yet)
You can actually change the session ID in the URL with anything you like: for example www.retrospected.com/game/hello_world
Try not to take a too common name though, to avoid anyone else finding your session by chance.
Many thanks to the following contributors who helped translating the app:
- Hungarian: @iaretiga
- Portuguese (Brazilian): @renancouto
- Dutch: @Sonaryr
- Russian: @vectart
- Spanish: @andresin87
- Chinese: @aqutw
- Polish: @olaf-cichocki
- Arabic: @Meshredded
- Japanese: @sat0yu
- German: @PaulBrandt
If you are a native speaker of another language, please don't hesitate to make a pull request to add a translation.
Special thanks to @andresin87 for pointing the flag-icon-css
package to me, it replaces the PNG flags in a neater way.
Another special thanks to Browserstack, as they allow me to test this project is other browsers.
Please make your PRs from the develop branch, not master.