1.1.1 • Published 9 years ago

@altimho/angular-apischeme v1.1.1

Weekly downloads
-
License
MIT
Repository
github
Last release
9 years ago

APIScheme

AngularJS module for translation of pseudo-url (like api://collection/items/3) to real url (https://example.com/collection/items/3). Useful for writing API calls, template URLs etc.

Using

Add altimho.apischeme module as dependency and register URL scheme in config section.

angular.module('example', [ 'altimho.apischeme' ])
  .config(function (APISchemeInterceptorProvider) {
    APISchemeInterceptorProvider.register('api', 'https://api.example.com');
    APISchemeInterceptorProvider.register('template', 'https://example.com/tpl');
  });

Now you can use URLs like api://items/1 (converted to https://api.example.com/items/1) and template://view-item.tpl.html (converted to https://example.com/tpl/view-item.tpl.html).

Building

Install dependencies and run make script.

npm install
make
1.1.1

9 years ago

1.1.0

9 years ago

1.0.0

9 years ago