diff options
Diffstat (limited to 'actionpack/CHANGELOG')
-rw-r--r-- | actionpack/CHANGELOG | 79 |
1 files changed, 77 insertions, 2 deletions
diff --git a/actionpack/CHANGELOG b/actionpack/CHANGELOG index cc19402243..2bb1461ec9 100644 --- a/actionpack/CHANGELOG +++ b/actionpack/CHANGELOG @@ -1,5 +1,82 @@ *Rails 3.1.0 (unreleased)* +* Only show dump of regular env methods on exception screen (not all the rack crap) [DHH] + +* auto_link has been removed with no replacement. If you still use auto_link + please install the rails_autolink gem: + http://github.com/tenderlove/rails_autolink + + [tenderlove] + +* Added streaming support, you can enable it with: [José Valim] + + class PostsController < ActionController::Base + stream :only => :index + end + + Please read the docs at `ActionController::Streaming` for more information. + +* Added `ActionDispatch::Request.ignore_accept_header` to ignore accept headers and only consider the format given as parameter [José Valim] + +* Created `ActionView::Renderer` and specified an API for `ActionView::Context`, check those objects for more information [José Valim] + +* Added `ActionController::ParamsWrapper` to wrap parameters into a nested hash, and will be turned on for JSON request in new applications by default [Prem Sichanugrist] + + This can be customized by setting `ActionController::Base.wrap_parameters` in `config/initializer/wrap_parameters.rb` + +* RJS has been extracted out to a gem. [fxn] + +* Implicit actions named not_implemented can be rendered. [Santiago Pastorino] + +* Wildcard route will always match the optional format segment by default. [Prem Sichanugrist] + + For example if you have this route: + + map '*pages' => 'pages#show' + + by requesting '/foo/bar.json', your `params[:pages]` will be equals to "foo/bar" with the request format of JSON. If you want the old 3.0.x behavior back, you could supply `:format => false` like this: + + map '*pages' => 'pages#show', :format => false + +* Added Base.http_basic_authenticate_with to do simple http basic authentication with a single class method call [DHH] + + class PostsController < ApplicationController + USER_NAME, PASSWORD = "dhh", "secret" + + before_filter :authenticate, :except => [ :index ] + + def index + render :text => "Everyone can see me!" + end + + def edit + render :text => "I'm only accessible if you know the password" + end + + private + def authenticate + authenticate_or_request_with_http_basic do |user_name, password| + user_name == USER_NAME && password == PASSWORD + end + end + end + + ..can now be written as + + class PostsController < ApplicationController + http_basic_authenticate_with :name => "dhh", :password => "secret", :except => :index + + def index + render :text => "Everyone can see me!" + end + + def edit + render :text => "I'm only accessible if you know the password" + end + end + +* Allow you to add `force_ssl` into controller to force browser to transfer data via HTTPS protocol on that particular controller. You can also specify `:only` or `:except` to specific it to particular action. [DHH and Prem Sichanugrist] + * Allow FormHelper#form_for to specify the :method as a direct option instead of through the :html hash [DHH] form_for(@post, remote: true, method: :delete) instead of form_for(@post, remote: true, html: { method: :delete }) @@ -37,8 +114,6 @@ tested. Keys are dasherized. Values are JSON-encoded, except for strings and symbols. [Stephen Celis] -* Added render :once. You can pass either a string or an array of strings and Rails will ensure they each of them are rendered just once. [José Valim] - * Deprecate old template handler API. The new API simply requires a template handler to respond to call. [José Valim] * :rhtml and :rxml were finally removed as template handlers. [José Valim] |