Uh oh!
There was an error while loading. Please reload this page.
Basic documentation of cache plugin methods option - #174
Conversation
dbu
left a comment
There was a problem hiding this comment.
thank you. i have some styling input and the thing we discussed on the code change, mention case sensitivity
| The third parameter to the ``CachePlugin`` constructor takes an array of options. The plugin has 3 options you can | ||
| The third parameter to the ``CachePlugin`` constructor takes an array of options. The plugin has four options you can | ||
| configure. Their default values and meaning is described by the table below. |
There was a problem hiding this comment.
maybe just:
"The available options are:"
| +===========================+=====================+======================================================+ | ||
| | ``default_ttl`` | ``0`` | The default max age of a Response | | ||
| +---------------------------+---------------------+------------------------------------------------------+ | ||
| | ``respect_cache_headers`` | ``true`` | Whatever or not we should care about cache headers | |
There was a problem hiding this comment.
s/Whatever/Whether/
(i see you only reformatted this, but just jumped into my eyes)
There was a problem hiding this comment.
I believe "Whether we should care about cache headers or not" would be proper english.
| 'methods' => ['GET', 'HEAD', 'POST'], | ||
| ]; | ||
| You can cache any valid request method. |
There was a problem hiding this comment.
maybe:
"methods" overwrites the default methods, if you want to keep caching GET and HEAD requests, you need to repeat them. You can specify any request method that conforms to RFC-7230. Note that request methods are case sensitive, so post and POST are not the same.
| ]; | ||
| The ``methods`` setting overrides the defaults. If you want to keep caching ``GET`` and ``HEAD`` requests, you need | ||
| to include them. You can specify any request method that conforms to RFC-7230. Request methods are case sensitive, |
There was a problem hiding this comment.
"Request methods are case sensitive,". I do not like this implementation. But I made some questions on the PR.
There was a problem hiding this comment.
php-http/cache-plugin#24 was now changed to force upper case. please change this line to say that.
There was a problem hiding this comment.
Yes, can #24 now be considered feature frozen?
| ]; | ||
| The ``methods`` setting overrides the defaults. If you want to keep caching ``GET`` and ``HEAD`` requests, you need | ||
| to include them. You can specify any request method that conforms to RFC-7230. Request methods are case sensitive, |
There was a problem hiding this comment.
php-http/cache-plugin#24 was now changed to force upper case. please change this line to say that.
dbu
commented
Feb 20, 2017
any other input or can we merge like this? should we maybe add some "since" notes? |
Nyholm
left a comment
There was a problem hiding this comment.
Good!
I do not think we need "since". All the docs relate to the latest version.
No description provided.