Build Rails applications faster with formation templatesPlan and bootstrap Rails application in the same time
Bootstrapping the Rails application may be boring. Usually, It comes down to the following steps:
- generating Rails skeleton
- creating models and validations
- adding gems for development
- generating test data
Also, if you don’t plan the architecture and details, you spend more time thinking about what kind of columns define for a given resource or which data should be validated. In brief, depending on the application size and your experience, you need from several minutes to a few hours before you can start implementing the business domain logic.
Speed up bootstrap of Rails application
To speed up the bootstrapping process, I designed the Rails formation library to bootstrap Rails application based on the templates in a JSON format called formations. You can create templates using a simple UI available for free at https://railsformation.com. If you are familiarized with AWS, the solution does the same for Rails as AWS CloudFormation does for the cloud infrastructure.
Why bother yourself with planning and creating templates if you can just jump straight into code and start writing? I found a few reasons for that:
- Thanks to planning, you spend more time writing logic and less time thinking about it.
- You keep the data in the database integrated because with formations, you define validations once, and they are applied to the model and migration level.
- You don’t have to look into the documentation to find out how to pass extra options for a given validation.
- You have a bigger picture of your application in place.
- You can plan the application with your team or your client, and when it’s ready - you are one command away from generating the fully working skeleton.
- You don’t care about test data as it is generated automatically based on the column definitions.
Learn how to use Rails formations
Even though Rails formation is in the BETA version, you can save a lot of time using it for your next Rails project. Take a look what it does and how it can help you: