diff --git a/README.md b/README.md index 445a3ada..c67a6bc9 100644 --- a/README.md +++ b/README.md @@ -805,7 +805,7 @@ template than for the layout by passing the `:layout_engine` option. CoffeeScript - and a + and a way to execute javascript @@ -836,9 +836,9 @@ template than for the layout by passing the `:layout_engine` option. Example - yajl :index, - :locals => { :key => 'qux' }, - :callback => 'present', + yajl :index, + :locals => { :key => 'qux' }, + :callback => 'present', :variable => 'resource' @@ -846,7 +846,7 @@ template than for the layout by passing the `:layout_engine` option. -The template source is evaluated as a Ruby string, and the +The template source is evaluated as a Ruby string, and the resulting json variable is converted using `#to_json`. ```ruby @@ -1859,12 +1859,12 @@ that case you can get it to set up session based protections by passing the `:se
absolute_redirects
- If disabled, Sinatra will allow relative redirects, however, Sinatra will no + If disabled, Sinatra will allow relative redirects, however, Sinatra will no longer conform with RFC 2616 (HTTP 1.1), which only allows absolute redirects.
- Enable if your app is running behind a reverse proxy that has not been set up - properly. Note that the url helper will still produce absolute URLs, unless you + Enable if your app is running behind a reverse proxy that has not been set up + properly. Note that the url helper will still produce absolute URLs, unless you pass in false as the second parameter.
Disabled per default.
@@ -1878,7 +1878,7 @@ that case you can get it to set up session based protections by passing the `:se
app_file
- Path to the main application file, used to detect project root, views and public + Path to the main application file, used to detect project root, views and public folder and inline templates.
@@ -1893,7 +1893,7 @@ that case you can get it to set up session based protections by passing the `:se
environment
- current environment, defaults to ENV['RACK_ENV'], or "development" if + current environment, defaults to ENV['RACK_ENV'], or "development" if not available.
@@ -1902,14 +1902,14 @@ that case you can get it to set up session based protections by passing the `:se
lock
- Places a lock around every request, only running processing on request + Places a lock around every request, only running processing on request per Ruby process concurrently.
Enabled if your app is not thread-safe. Disabled per default.
method_override
- use _method magic to allow put/delete forms in browsers that + use _method magic to allow put/delete forms in browsers that don't support it.
@@ -1918,7 +1918,7 @@ that case you can get it to set up session based protections by passing the `:se
prefixed_redirects
- Whether or not to insert request.script_name into redirects if no + Whether or not to insert request.script_name into redirects if no absolute path is given. That way redirect '/foo' would behave like redirect to('/foo'). Disabled per default.
@@ -1931,8 +1931,8 @@ that case you can get it to set up session based protections by passing the `:se
public_folder
- Path to the folder public files are served from. Only used if static - file serving is enabled (see static setting below). Inferred from + Path to the folder public files are served from. Only used if static + file serving is enabled (see static setting below). Inferred from app_file setting if not set.
@@ -1948,13 +1948,13 @@ that case you can get it to set up session based protections by passing the `:se
raise_errors
- raise exceptions (will stop application). Enabled by default when + raise exceptions (will stop application). Enabled by default when environment is set to "test", disabled otherwise.
run
- if enabled, Sinatra will handle starting the web server, do not + if enabled, Sinatra will handle starting the web server, do not enable if using rackup or other means.
@@ -1963,7 +1963,7 @@ that case you can get it to set up session based protections by passing the `:se
server
- server or list of servers to use for built-in server. defaults to + server or list of servers to use for built-in server. defaults to ['thin', 'mongrel', 'webrick'], order indicates priority.
@@ -2007,13 +2007,13 @@ that case you can get it to set up session based protections by passing the `:se
threaded
- If set to true, will tell Thin to use EventMachine.defer + If set to true, will tell Thin to use EventMachine.defer for processing the request.
views
- Path to the views folder. Inferred from app_file setting if + Path to the views folder. Inferred from app_file setting if not set.
@@ -2030,7 +2030,7 @@ There are three predefined `environments`: `"development"`, `"production"` and `"test"`. Environments can be set through the `RACK_ENV` environment variable. The default value is `"development"`. In the `"development"` environment all templates are reloaded between -requests, and special `not_found` and `error` handlers +requests, and special `not_found` and `error` handlers display stack traces in your browser. In the `"production"` and `"test"` environments, templates are cached by default. @@ -2198,7 +2198,7 @@ is recommended: end ``` -Note: If you are using Sinatra in the modular style, replace `Sinatra::Application` +Note: If you are using Sinatra in the modular style, replace `Sinatra::Application` above with the class name of your app. ## Sinatra::Base - Middleware, Libraries, and Modular Apps