Rx.DOM.Request.post(url, [body])
Creates an observable sequence from an Ajax POST Request with the body. This method is just shorthand for the Rx.DOM.Request.ajax
method with the POST method.
Syntax
Rx.DOM.Request.post(url, body);
Arguments
url
(String): A string of the URL to make the Ajax call.[body]
(Object): The body to post
Returns
(Observable): The observable sequence which contains the response from the Ajax POST.
Example
Rx.DOM.Request.post('/test')
.subscribe(
function (xhr) {
console.log(xhr.responseText);
},
function (err) {
// Log the error
}
);