All Versions
59
Latest Version
Avg Release Cycle
42 days
Latest Release
-

Changelog History
Page 3

  • v4.0.0.beta5

    • ๐Ÿฑ Assets bundled in engine cells now work.
    • ๐Ÿฑ Directory change: Assets like .css, .coffee and .js, no longer have their own assets/ directory but live inside the views directory of a cell. It turned out that two directories views/ and assets/ was too noisy for most users. If you think you have a valid point for re-introducing it, email me, it is not hard to implement.
    • ๐Ÿฑ When bundling your cell's assets into the asset pipeline, you have to specify the full name of your cell. The names will be constantized.

      config.cells.with_assets = ["song/cell", "user_cell"] #=> Song::Cell, UserCell
      
    • ๐Ÿš… ViewModel is now completely decoupled from Rails and doesn't inherit from AbstractController anymore.

    • API change: The controller dependency is now a second-class citizen being passed into the cell via options.

      Cell.new(model, {controller: ..})
      
    • Removing actionpack from gemspec.

  • v4.0.0.beta4

    • ๐Ÿ›  Fixed a bug when rendering more than once with ERB, the output buffer was being reused.
    • ๐Ÿ›  API change: ViewModel::_prefixes now returns the "fully qualified" pathes including the view paths, prepended to the prefixes. This allows multiple view paths and basically fixes cells in engines.
    • ๐Ÿ›  The only public way to retrieve prefixes for a cell is ViewModel::prefixes. The result is cached.
  • v4.0.0.beta3

    • โœ… Introduce Cell::Testing for Rspec and MiniTest.
    • โž• Add ViewModel::OutputBuffer to be used in Erbse and soon in Haml.
  • v3.11.2

    • ViewModel#call now accepts a block and yields self (the cell instance) to it. This is handy to use with content_for. ruby = cell(:song, Song.last).call(:show) do |cell| content_for :footer, cell.footer
  • v3.11.1

    • ๐Ÿšš Override ActionView::Helpers::UrlHelper#url_for in Rails 4.x as it is troublesome. That removes the annoying arguments passed to url_for can't be handled. Please require routes or provide your own implementation exception when using simple_form, form_for, etc with a view model.
  • v3.11.0

    • ๐Ÿ—„ Deprecated Cell::Rails::ViewModel, please inherit: class SongCell < Cell::ViewModel.
    • ViewModel#call is now the prefered way to invoke the rendering flow. Without any argument, call will run render_state(:show). Pass in any method name you want.
    • โž• Added Caching::Notifications.
    • โž• Added cell(:song, collection: [song1, song2]) to render collections. This only works with ViewModel (and, of course, Concept, too).
    • โž• Added ::inherit_views to only inherit views whereas real class inheritance would inherit all the dark past of the class.
    • ๐Ÿšš ::build_for removed/privatized/changed. Use Cell::Base::cell_for instead.
    • Base::_parent_prefixes is no longer used, if you override that somewhere in your cells it will break. We have our own implementation for computing the controller's prefixes in Cell::Base::Prefixes (simpler).
    • #expire_cell_state doesn't take symbols anymore, only the real cell class name.
    • Remove Cell::Base.setup_view_paths! and Cell::Base::DEFAULT_VIEW_PATHS and the associated Railtie. I don't know why this code survived 3 major versions, if you wanna set you own view paths just use Cell::Base.view_paths=.
    • โž• Add Base::self_contained!.
    • โž• Add Base::inherit_views.

    Concept

    • #concept helper is mixed into all views as an alternative to #cell and #render_cell. Let us know if we should do that conditionally, only.
    • Concept cells look for layouts in their self-contained views directory.
    • โž• Add generator for Concept cells: rails g concept Comment
  • v3.10.1

    ๐Ÿ‘ Allow packaging assets for Rails' asset pipeline into cells. This is still experimental but works great. I love it.

  • v3.10.0

    • API CHANGE: Blocks passed to ::cache and ::cache ... if: no longer receive the cell instance as the first argument. Instead, they're executed in cell instance context. Change your code like this: ```ruby cache :show do |cell, options| cell.version end
  • v3.9.2

    • ๐Ÿš… Autoload Cell::Rails::ViewModel.
    • Implement dynamic cache options by allowing lambdas that are executed at render-time - Thanks to @bibendi for this idea.
  • v3.9.1

    • ๐Ÿš… Runs with Rails 4.1 now.
    • Internal changes on Layouts to prepare 4.1 compat.