plugins: Create a plugins service with a Plugin definition

This commit is contained in:
David Cormier 2013-10-08 17:11:05 -04:00
parent 7db8e31a7f
commit 1fd6e1b0b6

View file

@ -1,7 +1,22 @@
var plugins = angular.module('plugins', []);
plugins.service('plugins', function() {
this.Plugin = function(contentForMessage) {
return {
contentForMessage: contentForMessage,
exclusive: false,
}
}
});
plugins.factory('pluginManager', ['youtubePlugin', 'urlPlugin', 'imagePlugin', function(youtubePlugin, urlPlugin, imagePlugin) {
var plugins = [youtubePlugin, urlPlugin, imagePlugin]
var hookPlugin = function(plugin) {