Company
Date Published
Author
Guest Andr
Word count
1835
Language
English
Hacker News points
None

Summary

André Elmoznino Laufer, a software developer at Valtech, shares his experience converting a legacy Ruby on Rails application into a modern React-based framework for the national Swedish Educational Broadcasting Company's UR Play streaming service. The transition was motivated by challenges such as high staff turnover, difficulty in recruiting Ruby on Rails experts, and the need to merge two distinct streaming platforms while rebranding. To ensure core functionality remained intact during the migration, Cypress was used extensively for end-to-end testing, attaching unique data attributes to track changes and employing a combination of Jest and Enzyme for unit tests. The process involved incrementally rewriting components, starting with the search page filters, and wrapping them into containers to manage state and logic. A significant aid in maintaining accessibility compliance was the cypress-axe plugin, which automatically detects accessibility violations. The approach also included mob programming to distribute knowledge across the team and using Cypress to validate the contract between the frontend and backend, ensuring the new system could be deployed efficiently without introducing errors.