Skip to content

nicbell/angular-scriptloader

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 

Repository files navigation

angular-scriptloader

Script loader for Angular. Inject scripts and returns a promise. Won't inject the same script twice.

NPM

npm i angular-scriptloader

Setup

angular.module('yourApp', [
    'nb.scriptloader'
]);

Service

Loading a script.

$scriptLoader.load('/example.js')
    .then(function() {
        //..
    });

Loading scripts concurrently.

$q.all([$scriptLoader.load('/example.js'), $scriptLoader.load('/example2.js')])
    .then(function() {
        //..
    });

About

Script loader for angular.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published