Created
August 29, 2020 08:34
-
-
Save elpddev/9d90dc485cb7c8da105856862cac0c27 to your computer and use it in GitHub Desktop.
AngularJs auth service directive usage #angularjs #medium #article-hierarchical-di-ng
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class MoviesList { | |
} | |
const MoviesListComponent = { | |
template: ` | |
<h1>Movies</h1> | |
<ul> | |
<li ng-repeat="movie in ($ctrl.movies.movies | promiseAsync) track by movie.id"> | |
{{ movie.name }} - {{ movie.year }} - {{ movie.rating }} | |
</li> | |
</ul> | |
`, | |
require: { | |
movies: '^', | |
}, | |
controller: MoviesList | |
}; | |
moviesApp.component('moviesList', MoviesListComponent); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment