Ruby on Rails Friday, January 26, 2018

Yes, you can

Model
project_folder/lib/templates/active_record/model/model.rb

Controller
project_folder/lib/templates/rails/scaffold_controller/controller.rb

Views
project_folder/lib/templates/erb/scaffold/

All the original file can be founded inside railties folder (bundle show railties)
You can also add views editing scaffold_generator.rb

Cheers
Mauro

2018-01-26 12:52 GMT+01:00 fugee ohu <fugee279@gmail.com>:
I can override any gem's controllers and views by creating them in my app?

--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe@googlegroups.com.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/51d6633b-81cc-41ef-b548-575feb06f086%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe@googlegroups.com.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/CANnJYrq90%2B1-zBnbqaTSkXN57A5OGen3p4txXTcAyU8veqi7YQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment