todomvc.com example built using rails 5, webpacker, react v16, redux and saga.
bundle install
cd vendor && yarn install && cd ..
foreman start
open http://localhost:5000/
If you wanna simulate a production environment compile the assets and run in production environment
rake assets:precompile # will compile webpack too
RAILS_SERVE_STATIC_FILES=true SECRET_KEY_BASE="secretkey" RAILS_ENV=production rails s -b 0.0.0.0 -p 5000
The code is port of a v0.13 react version, so I intend to make it follow the best practices described on v15 v16 documentation.
- Add system tests
- Add redux and rails API
- REST
- GraphQL
- add tests (probably current tests are broken because of login)
- Add Flow (or prop types?)
- improve index fetching (pagination, next url…)
- rehydrate JWT from localstorage
- navigate between all/completed/active using react router
- use humps and normalizr (good for complex APIs, but not needed on this case)
- use styled components for todo mvc css (so we can practice and find best practices)
- I’d like to remove (internal) state for some components and write them as functional, but not a big deal atm
Based on original work todomvc react created by petehunt.