In our settings (apps/web/application.rb), there is a code block that allows to share the code for all the views of our application.
When a view includes the Web::View module, that block code is yielded within the context of that class.
This is heavily inspired by Ruby Module and its included hook.
Imagine we have an application that only renders JSON.
For each view we should specify the handled format. This can be tedious to do by hand, but we can easily DRY our code.
We craft a module in apps/web/views/accept_json.rb.