angular-interceptor-module

Interceptor module with svg loading for AngularJS

Angular Core Dependency: ~1.2.22

Module License: MIT

Added by: Sam Deering

GitHub

Repository

agenciahulk/angular-interceptor-module

Stats

Stars: 3

Watchers: 3

Forks: 1

Module Description

Build Status

Angular Interceptor Module

Interceptor directive for all requests in angularJS.

Screenshot

##Using!

  1. Include the css file
<link rel="stylesheet" href="dist/styleAngularInterceptorModule.min.css">
  1. Include the Angular Interceptor Module
<script src="dist/AngularInterceptorModule.min.js"></script>
  1. Use in your HTML
<div w="150" h="150" c="#ffffff" bc="#E82C0C" loading-interceptor></div>

3.1 Explaining

  • w -> width
  • h -> height
  • c -> loader color
  • bc -> background box

##In your Angular application

angular.module('testeApp', ['ngRoute' , "interceptorApp.interceptionRequests", "interceptorApp.loadingInterceptor"])
  .config(function($routeProvider, $httpProvider){
    $routeProvider
      .when('/', {
        templateUrl: 'views/loader.html',
        controller: 'DashboardCtrl'
      }).otherwise({
          redirectTo: '/404'
      });

    //Http Intercpetor check and show loading
    $httpProvider.interceptors.push('interceptionRequests');
  });

Dependences

  • AngularJS
  • Jquery
  • AngularRoute

Currently running on Firefox, Opera, Safari, Chrome. IE coming soon :)

Contributing

  1. Fork it!
  2. Create your feature branch: git checkout -b my-new-feature
  3. Commit your changes: git commit -m 'Add some feature'
  4. Push to the branch: git push origin my-new-feature
  5. Submit a pull request :D

License

MIT License © Rodnei Ribeiro

Module stats last updated: 2015-06-04 11:08:50

Disclaimer: Some data on this page may have been gathered from the authors GitHub respository. If you see any mistakes or outdated information please let us know. Thanks!