You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
To explicitly allow parameters, the lesson suggests to use require with permit. However, I'm following the version 8 docs, but it strongly recommends to use expect, which "requires" and "permits" parameters all at once. The logic and syntax is understandable, but it kinda confused me which one should I use as I move forward in the curriculum, and even considered to downgrade the Rails version.
While this one is not originally an issue for me, I think it's also worth mentioning that the TOP lesson and docs exposes us about flash messages. The generated models and controllers in the project use a different syntax for the flash like so: format.html { redirect_to @car, notice: "Car was successfully updated." }, unlike the lesson's introduction to flash messages.
This clearly led to a confusion. I suggest that the lesson must expose us for what's to come when following the Rails 8 docs, as well as what Rails generates in the project (since I also explore the project at the same time). This way, we'll be prepared for content, we'll know which is better/suited for certain cases, and minimise confusion for different Rails versions.
I'm only going to address the stuff with strong parameters in my PR as that's already a solid chunk of work to consider and review. If you have strong feelings about the flash message stuff, I recommend opening a different issue for that so it can be tackled separately.
Checks
Describe your suggestion
My concerns are:
require
withpermit
. However, I'm following the version 8 docs, but it strongly recommends to useexpect
, which "requires" and "permits" parameters all at once. The logic and syntax is understandable, but it kinda confused me which one should I use as I move forward in the curriculum, and even considered to downgrade the Rails version.format.html { redirect_to @car, notice: "Car was successfully updated." }
, unlike the lesson's introduction to flash messages.This clearly led to a confusion. I suggest that the lesson must expose us for what's to come when following the Rails 8 docs, as well as what Rails generates in the project (since I also explore the project at the same time). This way, we'll be prepared for content, we'll know which is better/suited for certain cases, and minimise confusion for different Rails versions.
Path
Ruby / Rails
Lesson Url
https://www.theodinproject.com/lessons/ruby-on-rails-controllers
(Optional) Discord Name
Koko#8682
(Optional) Additional Comments
No response
The text was updated successfully, but these errors were encountered: