1.1.0 • Published 8 years ago

angular-theme v1.1.0

Weekly downloads
4
License
MIT
Repository
github
Last release
8 years ago

Angular Theme

Dynamic style and layout switching using Angular

API

Loading Themes

<head>
  <link href="/basic.css" ng-theme="basic" default />
  <link href="/dark.css" ng-theme="dark" />
</head>

Attributes:

  • ng-theme - Tells angular-theme about the style, and gives it a name for future reference
  • default - Specifies the style to show on load

Managing Themes Programatically

angular.controller('MyController', function($scope, $theme) {
  $scope.theme = $theme.activeTheme;
  $scope.$watch('theme', $theme.setTheme);
});

License

MIT