Skip to content

cfairweather/angularjs-json-rpc

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

AngularJS json rpc

This code is far from the repository from which it was forked. JSON-RPC-2.0 implementation for AngularJS.

For Usage see test.js.

An example JSFiddle is working here: http://jsfiddle.net/89D4b/1/

Instead of creating a new factory for handling jsonrpc request, this angular module (angular-json-rpc) creates a new shortcut just like $http.get, but is instead $http.jsonrpc;

This code is under WTFPL.

Author

Example usage:

In your module, import 'angular-json-rpc':

    angular.module('test-module-jsonrpc', ['angular-json-rpc'])

Then:

    //url, method, parameters, config
    $http.jsonrpc('url/to/jsonrpc/service', 'methodToCall', [1, 2, 3], {}).success(function(){}).error(function(){});

For more information on callacks, see $http.

About

angular-json-rpc for AngularJS

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 100.0%