From 83e286da3d354ad554b9e802a86c9dddadaf2f30 Mon Sep 17 00:00:00 2001 From: itoshusu Date: Fri, 24 Feb 2023 23:12:42 +0900 Subject: [PATCH] Update README with config to disable generation of decorator files --- README.md | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/README.md b/README.md index 97fef7f0..83f5cc59 100644 --- a/README.md +++ b/README.md @@ -155,6 +155,15 @@ rails generate decorator Article ...to create the `ArticleDecorator`. +If you don't want Rails to generate decorator files when generating a new controller, +you can add the following configuration to your `config/application.rb` file: + +```ruby +config.generators do |g| + g.decorator false +end +``` + ### Accessing Helpers Normal Rails helpers are still useful for lots of tasks. Both Rails' provided