All posts tagged with 'ruby on rails'
A refreshing take: using serverside rendering to reduce fragile DOM state
Hotwire is central to how we drive the frontend at FreeAgent, and Action Cable allows us to send Turbo Streams as users browse the site, adding a layer of richness to the user experience. Continue reading
Waiting for it with Capybara’s synchronize method
Feature specs are notorious for their potential to flake. It’s possible for the results of feature specs to be inconsistent because they have to deal with asynchronous state. In a typical test environment, there’s a single Ruby process at play, so test code will be executed in order as written – we can reasonably expect one line to complete before the next is executed. But when it comes to feature specs… Continue reading
Wiggling my way to a win
The work calendar At FreeAgent, we work in intervals of sprints (2 weeks) and cycles (which are made up of 4 sprints – adding up to roughly 2 months total). In a cycle a team typically aims to complete 1 larger project, and during a sprint a team aims to complete sub-tasks of that larger project. This helps construct timelines and structure for product managers and engineers to work within. … Continue reading
The Other Copilot: Coding with AI
It seems Copilots are ten a penny these days. While our CoPilot accountant partners are a human way to support you using FreeAgent, the flight term has really taken off(!) as branding for AI tools, GitHub’s Copilot being just one of them. The rise of AI tooling for developers has sparked a lot of discussion and controversy as of late. It’s also seen rapid development and innovation, with several code… Continue reading
Mission jQuery Zero: How FreeAgent removed jQuery from our application
Just over 3 years ago FreeAgent was running with 4 front-end frameworks, Stimulus, React with Redux, Rails UJS and jQuery and we were about to start adding Turbo to the stack. Running all these different frameworks was not sustainable and we chose to reduce our number of dependencies and first up was jQuery. We called this our legendary jQuery code, code that had helped us grow a business and provide… Continue reading
A case of missing validation messages
I’ve recently worked on two very similar issues within the FreeAgent app, which is a Rails web application. The problem that was reported in both cases was that when a user tried to submit invalid data they didn’t get any kind of message indicating what went wrong. In case it helps someone else (and let’s be honest to remind myself when I undoubtedly come across it again) I thought I’d… Continue reading
The architecture of FreeStyle, our design system
We embarked on a journey to create a design system at FreeAgent over 2 years ago. In this blog post I will describe how we structure our design system code and how it’s being used across different codebases. Technologies we use Our main design system consumer is the FreeAgent web application, a Ruby on Rails application. As a result, we write our components using the Ruby on Rails ViewComponent framework… Continue reading
Readable Dates in Rails
I was playing around in Swift recently, and wanted a reference to 'one day ago'. This is simple enough in human terms: if it's 9:30 on the 18th of September, 'one day ago' means 9:30 on the 17th of September. The Swift code to do this looks like this: Calendar.current.date( byAdding: .day, value: -1, to: Date.now ) ...and that's just a bit much, isn't it? First we need to access Calendar.current, a singleton… Continue reading
So you’re going to be an intern
After months of nerves, interviews and one too many LeetCode questions, you’ve done it. You’ve landed an internship, you’re free from the dread of a long, empty summer and your brain is filled with vague notions of what your internship might be like. I’m here to gather up your brain clay and sculpt it into solid ideas of what things will be like. Before we start, it needs to be… Continue reading
The legendary data warehouse application
In spring 2014, I created an internal Ruby on Rails app called data-warehouse. In this blog post I’m going to describe what it was, how it came to be and why, against what would appear to be all reasonable logic, it became the central part of our data infrastructure for about eight years. Continue reading