Skip to content
This repository has been archived by the owner on Mar 13, 2018. It is now read-only.

Commit

Permalink
Copyedits
Browse files Browse the repository at this point in the history
  • Loading branch information
Arthur Evans committed Feb 22, 2014
1 parent bfe238a commit b0ef32a
Showing 1 changed file with 19 additions and 12 deletions.
31 changes: 19 additions & 12 deletions polymer-ajax.html
Original file line number Diff line number Diff line change
Expand Up @@ -9,17 +9,24 @@
*/
/**
* polymer-ajax can be used to perform XMLHttpRequests.
*
* Note: The params attribute must be double quoted JSON
* The `polymer-ajax` element performs `XMLHttpRequest`s.
*
* You can trigger a request explicitly by calling `go` on the
* element.
*
* With `auto` set to `true`, the element performs a request whenever
* its `url` or `params` properties are changed.
*
*
* Example:
*
* <polymer-ajax auto url="http://gdata.youtube.com/feeds/api/videos/"
* params='{"alt":"json", "q":"chrome"}'
* handleAs="json"
* on-polymer-response="{{handleResponse}}">
* </polymer-ajax>
*
* Note: The `params` attribute must be double quoted JSON.
*
* @class polymer-ajax
* @status beta
Expand Down Expand Up @@ -61,24 +68,24 @@
*/
url: '',
/**
* Specifies what data to store in the 'response' property, and
* to deliver as 'event.response' in 'response' events.
* Specifies what data to store in the `response` property, and
* to deliver as `event.response` in `response` events.
*
* One of:
*
* `text`: uses XHR.responseText
* `text`: uses `XHR.responseText`.
*
* `xml`: uses XHR.responseXML
* `xml`: uses `XHR.responseXML`.
*
* `json`: uses XHR.responseText parsed as JSON
* `json`: uses `XHR.responseText` parsed as JSON.
*
* @attribute handleAs
* @type string
* @default 'text'
*/
handleAs: '',
/**
* If true, automatically performs an Ajax request when either url or params has changed.
* If true, automatically performs an Ajax request when either `url` or `params` changes.
*
* @attribute auto
* @type boolean
Expand All @@ -102,7 +109,7 @@
*/
response: null,
/**
* The HTTP method to use such as 'GET', 'POST', 'PUT', 'DELETE'.
* The HTTP method to use such as 'GET', 'POST', 'PUT', or 'DELETE'.
* Default is 'GET'.
*
* @attribute method
Expand All @@ -127,7 +134,7 @@
*/
headers: null,
/**
* Optional raw body content to send when method === "POST"
* Optional raw body content to send when method === "POST".
*
* Example:
*
Expand Down Expand Up @@ -218,7 +225,7 @@
}
},
/**
* Performs an Ajax request to the url specified.
* Performs an Ajax request to the specified URL.
*
* @method go
*/
Expand Down

0 comments on commit b0ef32a

Please sign in to comment.