Permalink
Browse files

releasing 3.11.0.

  • Loading branch information...
1 parent b26fd47 commit aad10f7664fca1ef1d24c0b0fe7de05a256539bc @apotonick apotonick committed May 29, 2014
Showing with 11 additions and 7 deletions.
  1. +7 −5 CHANGES.md
  2. +3 −1 README.md
  3. +1 −1 lib/cells/version.rb
View
@@ -1,18 +1,20 @@
## 3.11.0
* Deprecated `Cell::Rails::ViewModel`, please inherit: `class SongCell < Cell::ViewModel`.
-* `ViewModel#call`
+* `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).
-
-### 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.
-
* 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.
## 3.10.1
View
@@ -444,7 +444,9 @@ The `#cell` helper gives you an instance of the `SongCell` cell and wraps the `s
### Rendering
-The `call` invocation instructs the cell to render. You can basically call any method you want (and define) on that cell, nevertheless, a view model should only expose the `#show` method per convention - `#show` is invoked by `call`.
+The `call` invocation instructs the cell to render. Internally, that runs `render_state(:show)` per default.
+
+You can basically invoke any method you want on that cell. Nevertheless, a view model should only expose the `#show` method per convention, which is reflected by the `#call` alias.
It is important to understand this convention: Internally, you may render multiple views, combine them, use instance methods to render and format values, and so on. Externally, exposing only one "public", rendering method defines a strong interface for your view model.
@@ -1,3 +1,3 @@
module Cells
- VERSION = '3.10.1'
+ VERSION = '3.11.0'
end

0 comments on commit aad10f7

Please sign in to comment.