mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
Merge branch 'master' of github.com:lifo/docrails
This commit is contained in:
commit
95fdaf965a
4 changed files with 10 additions and 10 deletions
|
@ -67,7 +67,7 @@ We encourage you to contribute to Ruby on Rails! Please check out the {Contribut
|
||||||
guide}[http://edgeguides.rubyonrails.org/contributing_to_ruby_on_rails.html] for guidelines about how
|
guide}[http://edgeguides.rubyonrails.org/contributing_to_ruby_on_rails.html] for guidelines about how
|
||||||
to proceed. {Join us}[http://contributors.rubyonrails.org]!
|
to proceed. {Join us}[http://contributors.rubyonrails.org]!
|
||||||
|
|
||||||
== Travis Build Status {<img src="https://secure.travis-ci.org/rails/rails.png"/>}[https://secure.travis-ci.org/rails/rails.png]
|
== Travis Build Status {<img src="https://secure.travis-ci.org/rails/rails.png"/>}[http://travis-ci.org/rails/rails]
|
||||||
|
|
||||||
== License
|
== License
|
||||||
|
|
||||||
|
|
|
@ -1020,7 +1020,7 @@ class A
|
||||||
class_attribute :x, :instance_reader => false
|
class_attribute :x, :instance_reader => false
|
||||||
end
|
end
|
||||||
|
|
||||||
A.x = 1 # NoMethodError
|
A.new.x = 1 # NoMethodError
|
||||||
</ruby>
|
</ruby>
|
||||||
|
|
||||||
For convenience +class_attribute+ also defines an instance predicate which is the double negation of what the instance reader returns. In the examples above it would be called +x?+.
|
For convenience +class_attribute+ also defines an instance predicate which is the double negation of what the instance reader returns. In the examples above it would be called +x?+.
|
||||||
|
|
|
@ -282,7 +282,7 @@ When debug mode is off Sprockets will concatenate and run the necessary preproce
|
||||||
<script src='/assets/application.js'></script>
|
<script src='/assets/application.js'></script>
|
||||||
</html>
|
</html>
|
||||||
|
|
||||||
Assets are compiled and cached on the first request after the server is started. Sprockets sets a +must-validate+ Cache-Control HTTP header to reduce request overhead on subsequent requests -- on these the browser gets a 304 (not-modified) response.
|
Assets are compiled and cached on the first request after the server is started. Sprockets sets a +must-revalidate+ Cache-Control HTTP header to reduce request overhead on subsequent requests -- on these the browser gets a 304 (not-modified) response.
|
||||||
|
|
||||||
If any of the files in the manifest have changed between requests, the server responds with a new compiled file.
|
If any of the files in the manifest have changed between requests, the server responds with a new compiled file.
|
||||||
|
|
||||||
|
@ -415,12 +415,12 @@ For Apache:
|
||||||
RewriteCond %{REQUEST_FILENAME}.gz -s
|
RewriteCond %{REQUEST_FILENAME}.gz -s
|
||||||
RewriteRule ^(.+) $1.gz [L]
|
RewriteRule ^(.+) $1.gz [L]
|
||||||
</LocationMatch>
|
</LocationMatch>
|
||||||
|
|
||||||
# without these, Content-Type will be "application/x-gzip"
|
# without these, Content-Type will be "application/x-gzip"
|
||||||
<FilesMatch "^/assets/.*\.css.gz$">
|
<FilesMatch "^/assets/.*\.css.gz$">
|
||||||
ForceType text/css
|
ForceType text/css
|
||||||
</FilesMatch>
|
</FilesMatch>
|
||||||
|
|
||||||
<FilesMatch "^/assets/.*\.js.gz$">
|
<FilesMatch "^/assets/.*\.js.gz$">
|
||||||
ForceType text/javascript
|
ForceType text/javascript
|
||||||
</FilesMatch>
|
</FilesMatch>
|
||||||
|
|
|
@ -549,9 +549,9 @@ folders, and edit <tt>config/routes.rb</tt>. Here's a quick overview of what it
|
||||||
|app/views/posts/new.html.erb |A view to create a new post|
|
|app/views/posts/new.html.erb |A view to create a new post|
|
||||||
|app/views/posts/_form.html.erb |A partial to control the overall look and feel of the form used in edit and new views|
|
|app/views/posts/_form.html.erb |A partial to control the overall look and feel of the form used in edit and new views|
|
||||||
|app/helpers/posts_helper.rb |Helper functions to be used from the post views|
|
|app/helpers/posts_helper.rb |Helper functions to be used from the post views|
|
||||||
|app/assets/stylesheets/scaffolds.css.scss |Cascading style sheet to make the scaffolded views look better|
|
|app/assets/stylesheets/scaffolds.css.scss |Cascading style sheet to make the scaffolded views look better|
|
||||||
|app/assets/stylesheets/posts.css.scss |Cascading style sheet for the posts controller|
|
|app/assets/stylesheets/posts.css.scss |Cascading style sheet for the posts controller|
|
||||||
|app/assets/javascripts/posts.js.coffee |CoffeeScript for the posts controller|
|
|app/assets/javascripts/posts.js.coffee |CoffeeScript for the posts controller|
|
||||||
|test/unit/post_test.rb |Unit testing harness for the posts model|
|
|test/unit/post_test.rb |Unit testing harness for the posts model|
|
||||||
|test/functional/posts_controller_test.rb |Functional testing harness for the posts controller|
|
|test/functional/posts_controller_test.rb |Functional testing harness for the posts controller|
|
||||||
|test/unit/helpers/posts_helper_test.rb |Unit testing harness for the posts helper|
|
|test/unit/helpers/posts_helper_test.rb |Unit testing harness for the posts helper|
|
||||||
|
@ -821,8 +821,8 @@ this layout in your editor and modify the +body+ tag:
|
||||||
<html>
|
<html>
|
||||||
<head>
|
<head>
|
||||||
<title>Blog</title>
|
<title>Blog</title>
|
||||||
<%= stylesheet_link_tag :all %>
|
<%= stylesheet_link_tag "application" %>
|
||||||
<%= javascript_include_tag :defaults %>
|
<%= javascript_include_tag "application" %>
|
||||||
<%= csrf_meta_tags %>
|
<%= csrf_meta_tags %>
|
||||||
</head>
|
</head>
|
||||||
<body style="background: #EEEEEE;">
|
<body style="background: #EEEEEE;">
|
||||||
|
|
Loading…
Reference in a new issue