Skip to content

trailblazer/cells-rails

Folders and files

NameName
Last commit message
Last commit date

Latest commit

77ff22a · Nov 13, 2024

History

99 Commits
Nov 13, 2024
Nov 13, 2024
Nov 13, 2024
Nov 13, 2024
Jun 9, 2022
Jun 9, 2022
Nov 13, 2024
Nov 13, 2024
Nov 13, 2024
Nov 13, 2024
May 12, 2022
Jun 9, 2022
Nov 13, 2024

Repository files navigation

Cells::Rails

CI

Cells is a generic view model implementation for Ruby. Cells-rails brings Rails-specific bindings.

Rails Features

  • All asset-related helpers are now simply delegated to the global asset helper instance. This happens by automatically including Cell::Helper::AssetHelper into ViewModel.
  • The global controller is passed to all cells via the context object. It's available via ViewModel#controller.
  • ViewModel#call and Collection#call are automatically html_safeed.

Installation

Note that cells-rails is designed to work with Cells >= 4.1.

Add this line to your application's Gemfile and keep it real:

gem 'cells-rails'

License

The gem is available as open source under the terms of the MIT License.