README.md in stairwell-0.6.4 vs README.md in stairwell-0.6.5
- old
+ new
@@ -16,9 +16,16 @@
Or install it yourself as:
$ gem install stairwell
+## Requirements
+`zeitwerk` gem, so make sure you have rails 7
+`activeRecord` gem.
+
+## Warnings
+Never accept params from a form directly into any sql, it's dangerous, and can lead to horrible outcomes. Cool? Great!
+
## Why?
Although ActiveRecord serves as an excellent tool for the majority of database queries, certain scenarios call for more customized queries.
This project was initially conceived to help transition a development team and their project from PHP to Ruby. This PHP project had thousands of complex SQL queries, thus the necessity of making SQL a first-class citizen in the ruby project enabled a smoother transition.
So, why not Arel? Arel is a powerful tool, but it's worth noting that it is considered a private API and is likely to remain so for the forseeable future.
Does this approach make queries less composable? Yes, if you are used to chaining your arel queries and AR scopes then you're probably not going to use this. However, it provides an interface that enables you to leverage SQL securely in your Ruby projects without the need to reinvent the wheel.