Add missing headers to Action Pack docs [ci-skip]
Having a h1 heading will improve SEO and makes things look more consistent.
This commit is contained in:
parent
138a9d2031
commit
168c206e06
@ -26,6 +26,8 @@ def corrections # :nodoc:
|
||||
end
|
||||
end
|
||||
|
||||
# = AbstractController \Base
|
||||
#
|
||||
# AbstractController::Base is a low-level API. Nobody should be
|
||||
# using it directly, and subclasses (like ActionController::Base) are
|
||||
# expected to provide their own +render+ method, since rendering means
|
||||
|
@ -2,6 +2,8 @@
|
||||
|
||||
module AbstractController
|
||||
module Caching
|
||||
# = AbstractController Caching \Fragments
|
||||
#
|
||||
# Fragment caching is used for caching various blocks within
|
||||
# views without caching the entire action as a whole. This is
|
||||
# useful when certain elements of an action change frequently or
|
||||
|
@ -5,6 +5,8 @@
|
||||
require "action_controller/log_subscriber"
|
||||
|
||||
module ActionController
|
||||
# = Action \Controller \Base
|
||||
#
|
||||
# API Controller is a lightweight version of ActionController::Base,
|
||||
# created for applications that don't require all functionalities that a complete
|
||||
# \Rails controller provides, allowing you to create controllers with just the
|
||||
|
@ -5,6 +5,8 @@
|
||||
require "action_controller/metal/params_wrapper"
|
||||
|
||||
module ActionController
|
||||
# = Action Controller \Base
|
||||
#
|
||||
# Action Controllers are the core of a web request in \Rails. They are made up of one or more actions that are executed
|
||||
# on request and then either it renders a template or redirects to another action. An action is defined as a public method
|
||||
# on the controller, which will automatically be made accessible to the web-server through \Rails Routes.
|
||||
|
@ -1,6 +1,8 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
module ActionController
|
||||
# = Action Controller \Caching
|
||||
#
|
||||
# \Caching is a cheap way of speeding up slow applications by keeping the result of
|
||||
# calculations, renderings, and database calls around for subsequent requests.
|
||||
#
|
||||
|
@ -1,6 +1,8 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
module ActionController
|
||||
# = Action Controller Form Builder
|
||||
#
|
||||
# Override the default form builder for all views rendered by this
|
||||
# controller and any of its descendants. Accepts a subclass of
|
||||
# ActionView::Helpers::FormBuilder.
|
||||
|
@ -4,6 +4,8 @@
|
||||
require "action_dispatch/middleware/stack"
|
||||
|
||||
module ActionController
|
||||
# = Action Controller \MiddlewareStack
|
||||
#
|
||||
# Extend ActionDispatch middleware stack to make it aware of options
|
||||
# allowing the following syntax in controllers:
|
||||
#
|
||||
@ -58,6 +60,8 @@ def build_middleware(klass, args, block)
|
||||
end
|
||||
end
|
||||
|
||||
# = Action Controller \Metal
|
||||
#
|
||||
# <tt>ActionController::Metal</tt> is the simplest possible controller, providing a
|
||||
# valid Rack interface without the additional niceties provided by
|
||||
# ActionController::Base.
|
||||
|
@ -4,6 +4,8 @@
|
||||
require "action_dispatch/http/content_disposition"
|
||||
|
||||
module ActionController # :nodoc:
|
||||
# = Action Controller Data Streaming
|
||||
#
|
||||
# Methods for sending arbitrary data and for streaming files to the browser,
|
||||
# instead of rendering.
|
||||
module DataStreaming
|
||||
|
@ -1,6 +1,8 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
module ActionController
|
||||
# = Action Controller Default Headers
|
||||
#
|
||||
# Allows configuring default headers that will be automatically merged into
|
||||
# each response.
|
||||
module DefaultHeaders
|
||||
|
@ -1,6 +1,8 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
module ActionController
|
||||
# = Action Controller Etag With Flash
|
||||
#
|
||||
# When you're using the flash, it's generally used as a conditional on the view.
|
||||
# This means the content of the view depends on the flash. Which in turn means
|
||||
# that the ETag for a response should be computed with the content of the flash
|
||||
|
@ -1,6 +1,8 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
module ActionController
|
||||
# = Action Controller Etag With Template Digest
|
||||
#
|
||||
# When our views change, they should bubble up into HTTP cache freshness
|
||||
# and bust browser caches. So the template digest for the current action
|
||||
# is automatically included in the ETag.
|
||||
|
@ -1,6 +1,8 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
module ActionController
|
||||
# = Action Controller Implicit Render
|
||||
#
|
||||
# Handles implicit rendering for a controller action that does not
|
||||
# explicitly respond with +render+, +respond_to+, +redirect+, or +head+.
|
||||
#
|
||||
|
@ -4,6 +4,8 @@
|
||||
require "abstract_controller/logger"
|
||||
|
||||
module ActionController
|
||||
# = Action Controller \Instrumentation
|
||||
#
|
||||
# Adds instrumentation to several ends in ActionController::Base. It also provides
|
||||
# some hooks related with process_action. This allows an ORM like Active Record
|
||||
# and/or DataMapper to plug in ActionController and show related information.
|
||||
|
@ -5,6 +5,8 @@
|
||||
require "active_support/json"
|
||||
|
||||
module ActionController
|
||||
# = Action Controller \Live
|
||||
#
|
||||
# Mix this module into your controller, and all actions in that controller
|
||||
# will be able to stream data to the client as it's written.
|
||||
#
|
||||
|
@ -6,6 +6,8 @@
|
||||
require "action_dispatch/http/mime_type"
|
||||
|
||||
module ActionController
|
||||
# = Action Controller Params Wrapper
|
||||
#
|
||||
# Wraps the parameters hash into a nested hash. This will allow clients to
|
||||
# submit requests without having to specify any root elements.
|
||||
#
|
||||
|
@ -11,6 +11,8 @@ class InvalidAuthenticityToken < ActionControllerError # :nodoc:
|
||||
class InvalidCrossOriginRequest < ActionControllerError # :nodoc:
|
||||
end
|
||||
|
||||
# = Action Controller Request Forgery Protection
|
||||
#
|
||||
# Controller actions are protected from Cross-Site Request Forgery (CSRF) attacks
|
||||
# by including a token in the rendered HTML for your application. This token is
|
||||
# stored as a random string in the session, to which an attacker does not have
|
||||
|
@ -1,6 +1,8 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
module ActionController # :nodoc:
|
||||
# = Action Controller \Rescue
|
||||
#
|
||||
# This module is responsible for providing +rescue_from+ helpers
|
||||
# to controllers and configuring when detailed exceptions must be
|
||||
# shown.
|
||||
|
@ -3,6 +3,8 @@
|
||||
require "rack/chunked"
|
||||
|
||||
module ActionController # :nodoc:
|
||||
# = Action Controller \Streaming
|
||||
#
|
||||
# Allows views to be streamed back to the client as they are rendered.
|
||||
#
|
||||
# By default, Rails renders views by first rendering the template
|
||||
|
@ -1,6 +1,8 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
module ActionController
|
||||
# = Action Controller \UrlFor
|
||||
#
|
||||
# Includes +url_for+ into the host class. The class has to provide a +RouteSet+ by implementing
|
||||
# the <tt>_routes</tt> method. Otherwise, an exception will be raised.
|
||||
#
|
||||
|
@ -1,6 +1,8 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
module ActionController
|
||||
# = Action Controller \Renderer
|
||||
#
|
||||
# ActionController::Renderer allows you to render arbitrary templates without
|
||||
# being inside a controller action.
|
||||
#
|
||||
|
@ -4,6 +4,8 @@
|
||||
require "active_support/core_ext/array/wrap"
|
||||
|
||||
module ActionDispatch # :nodoc:
|
||||
# = Action Dispatch Content Security Policy
|
||||
#
|
||||
# Configures the HTTP
|
||||
# {Content-Security-Policy}[https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy]
|
||||
# response header to help protect against XSS and injection attacks.
|
||||
|
@ -4,6 +4,8 @@
|
||||
|
||||
module ActionDispatch
|
||||
module Http
|
||||
# = Action Dispatch HTTP Filter Parameters
|
||||
#
|
||||
# Allows you to specify sensitive query string and POST parameters to filter
|
||||
# from the request log.
|
||||
#
|
||||
|
@ -2,6 +2,8 @@
|
||||
|
||||
module ActionDispatch
|
||||
module Http
|
||||
# = Action Dispatch HTTP \Headers
|
||||
#
|
||||
# Provides access to the request's HTTP headers from the environment.
|
||||
#
|
||||
# env = { "CONTENT_TYPE" => "text/plain", "HTTP_USER_AGENT" => "curl/7.43.0" }
|
||||
|
@ -3,6 +3,8 @@
|
||||
require "active_support/core_ext/object/deep_dup"
|
||||
|
||||
module ActionDispatch # :nodoc:
|
||||
# = Action Dispatch \PermissionsPolicy
|
||||
#
|
||||
# Configures the HTTP
|
||||
# {Feature-Policy}[https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Feature-Policy]
|
||||
# response header to specify which browser features the current document and
|
||||
|
@ -6,6 +6,8 @@
|
||||
require "monitor"
|
||||
|
||||
module ActionDispatch # :nodoc:
|
||||
# = Action Dispatch \Response
|
||||
#
|
||||
# Represents an HTTP response generated by a controller action. Use it to
|
||||
# retrieve the current state of the response, or customize the response. It can
|
||||
# either represent a real HTTP response (i.e. one that is meant to be sent
|
||||
|
@ -2,6 +2,8 @@
|
||||
|
||||
module ActionDispatch
|
||||
module Http
|
||||
# = Action Dispatch HTTP \UploadedFile
|
||||
#
|
||||
# Models uploaded files.
|
||||
#
|
||||
# The actual file is accessible via the +tempfile+ accessor, though some
|
||||
|
@ -1,6 +1,8 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
module ActionDispatch
|
||||
# = Action Dispatch \AssumeSSL
|
||||
#
|
||||
# When proxying through a load balancer that terminates SSL, the forwarded request will appear
|
||||
# as though its HTTP instead of HTTPS to the application. This makes redirects and cookie
|
||||
# security target HTTP instead of HTTPS. This middleware makes the server assume that the
|
||||
|
@ -1,6 +1,8 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
module ActionDispatch
|
||||
# = Action Dispatch \Callbacks
|
||||
#
|
||||
# Provides callbacks to be executed before and after dispatching the request.
|
||||
class Callbacks
|
||||
include ActiveSupport::Callbacks
|
||||
|
@ -6,6 +6,8 @@
|
||||
require "action_view"
|
||||
|
||||
module ActionDispatch
|
||||
# = Action Dispatch \DebugExceptions
|
||||
#
|
||||
# This middleware is responsible for logging exceptions and
|
||||
# showing a debugging page in case the request is local.
|
||||
class DebugExceptions
|
||||
|
@ -1,6 +1,8 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
module ActionDispatch
|
||||
# = Action Dispatch \DebugLocks
|
||||
#
|
||||
# This middleware can be used to diagnose deadlocks in the autoload interlock.
|
||||
#
|
||||
# To use it, insert it near the top of the middleware stack, using
|
||||
|
@ -3,6 +3,8 @@
|
||||
require "active_support/core_ext/hash/keys"
|
||||
|
||||
module ActionDispatch
|
||||
# = Action Dispatch \Flash
|
||||
#
|
||||
# The flash provides a way to pass temporary primitive-types (String, Array, Hash) between actions. Anything you place in the flash will be exposed
|
||||
# to the very next action and then cleared out. This is a great way of doing notices and alerts, such as a create
|
||||
# action that sets <tt>flash[:notice] = "Post successfully created"</tt> before redirecting to a display action that can
|
||||
|
@ -1,6 +1,8 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
module ActionDispatch
|
||||
# = Action Dispatch \HostAuthorization
|
||||
#
|
||||
# This middleware guards from DNS rebinding attacks by explicitly permitting
|
||||
# the hosts a request can be sent to, and is passed the options set in
|
||||
# +config.host_authorization+.
|
||||
|
@ -1,6 +1,8 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
module ActionDispatch
|
||||
# = ActionDispatch \PublicExceptions
|
||||
#
|
||||
# When called, this middleware renders an error page. By default if an HTML
|
||||
# response is expected it will render static error pages from the <tt>/public</tt>
|
||||
# directory. For example when this middleware receives a 500 response it will
|
||||
|
@ -1,6 +1,8 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
module ActionDispatch
|
||||
# = Action Dispatch \Reloader
|
||||
#
|
||||
# ActionDispatch::Reloader wraps the request with callbacks provided by
|
||||
# ActiveSupport::Reloader, intended to assist with code reloading during
|
||||
# development.
|
||||
|
@ -3,6 +3,8 @@
|
||||
require "ipaddr"
|
||||
|
||||
module ActionDispatch
|
||||
# = Action Dispatch \RemoteIp
|
||||
#
|
||||
# This middleware calculates the IP address of the remote client that is
|
||||
# making the request. It does this by checking various headers that could
|
||||
# contain the address, and then picking the last-set address that is not
|
||||
|
@ -4,6 +4,8 @@
|
||||
require "active_support/core_ext/string/access"
|
||||
|
||||
module ActionDispatch
|
||||
# = Action Dispatch \RequestId
|
||||
#
|
||||
# Makes a unique request id available to the +action_dispatch.request_id+ env variable (which is then accessible
|
||||
# through ActionDispatch::Request#request_id or the alias ActionDispatch::Request#uuid) and sends
|
||||
# the same id to the client via the +X-Request-Id+ header.
|
||||
|
@ -4,6 +4,8 @@
|
||||
|
||||
module ActionDispatch
|
||||
module Session
|
||||
# = Action Dispatch Session \CacheStore
|
||||
#
|
||||
# A session store that uses an ActiveSupport::Cache::Store to store the sessions. This store is most useful
|
||||
# if you don't store critical data in your sessions and you don't need them to live for extended periods
|
||||
# of time.
|
||||
|
@ -6,6 +6,8 @@
|
||||
|
||||
module ActionDispatch
|
||||
module Session
|
||||
# = ActionDispatch Session \CookieStore
|
||||
#
|
||||
# This cookie-based session store is the Rails default. It is
|
||||
# dramatically faster than the alternatives.
|
||||
#
|
||||
|
@ -10,6 +10,8 @@
|
||||
|
||||
module ActionDispatch
|
||||
module Session
|
||||
# = Action Dispatch Session \MemCacheStore
|
||||
#
|
||||
# A session store that uses MemCache to implement storage.
|
||||
#
|
||||
# ==== Options
|
||||
|
@ -3,6 +3,8 @@
|
||||
require "action_dispatch/middleware/exception_wrapper"
|
||||
|
||||
module ActionDispatch
|
||||
# = Action Dispatch \ShowExceptions
|
||||
#
|
||||
# This middleware rescues any exception returned by the application
|
||||
# and calls an exceptions app that will wrap it in a format for the end user.
|
||||
#
|
||||
|
@ -1,6 +1,8 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
module ActionDispatch
|
||||
# = Action Dispatch \SSL
|
||||
#
|
||||
# This middleware is added to the stack when <tt>config.force_ssl = true</tt>, and is passed
|
||||
# the options set in +config.ssl_options+. It does three jobs to enforce secure HTTP
|
||||
# requests:
|
||||
|
@ -3,6 +3,8 @@
|
||||
require "rack/utils"
|
||||
|
||||
module ActionDispatch
|
||||
# = Action Dispatch \Static
|
||||
#
|
||||
# This middleware serves static files from disk, if available.
|
||||
# If no file is found, it hands off to the main app.
|
||||
#
|
||||
@ -24,6 +26,8 @@ def call(env)
|
||||
end
|
||||
end
|
||||
|
||||
# = ActionDispatch \FileHandler
|
||||
#
|
||||
# This endpoint serves static files from disk using +Rack::Files+.
|
||||
#
|
||||
# URL paths are matched with static files according to expected
|
||||
|
@ -2,6 +2,8 @@
|
||||
|
||||
module ActionDispatch
|
||||
module Routing
|
||||
# = Action Dispatch Routing \PolymorphicRoutes
|
||||
#
|
||||
# Polymorphic URL helpers are methods for smart resolution to a named route call when
|
||||
# given an Active Record model instance. They are to be used in combination with
|
||||
# ActionController::Resources.
|
||||
|
@ -2,6 +2,8 @@
|
||||
|
||||
module ActionDispatch
|
||||
module Routing
|
||||
# = Action Dispatch Routing \UrlFor
|
||||
#
|
||||
# In <tt>config/routes.rb</tt> you define URL-to-controller mappings, but the reverse
|
||||
# is also possible: a URL can be generated from one of your routing definitions.
|
||||
# URL generation functionality is centralized in this module.
|
||||
|
Loading…
Reference in New Issue
Block a user