instance method
module_namespacing
Ruby on Rails 5.2.8.1
Since v5.2.8.1 PrivateSignature
module_namespacing(&block)
Wrap block with namespace of current application if namespace exists and is not skipped
Parameters
-
blockblock
Source
# File railties/lib/rails/generators/base.rb, line 285
def module_namespacing(&block) # :doc:
content = capture(&block)
content = wrap_with_namespace(content) if namespaced?
concat(content)
end
Defined in railties/lib/rails/generators/base.rb line 285
· View on GitHub
· Improve this page
· Find usages on GitHub
Defined in Rails::Generators::Base