Permalink
Browse files

notes for plugin architecture

  • Loading branch information...
1 parent d8d7202 commit 6ecb498416f5896c1d4d254133e631cfd914864f @enjalot committed Oct 30, 2012
Showing with 32 additions and 0 deletions.
  1. +32 −0 src/plugin.js
View
@@ -0,0 +1,32 @@
+
+
+/*
+//proposed plugin archictecture
+
+
+
+function extraCharts (tributary, options) {
+ //Stuff goes here
+ tributary.extras = setupExtras(options);
+}
+
+//
+Tributary.prototype.plugin = function (decorator, opts) {
+ decorator(this, opts);
+}
+
+
+tributary.plugin(extraCharts,{
+ svg: true
+});
+
+tributary.plugins('https://github.com/enjalot/special-plugin', 'http...github.../another-plugin', function (a, b) {
+});
+
+//can point to github repo, or potentially a gist
+//if a gist or repo has proper structure it becomes easy to plugin
+
+browserify
+common.js, AMD
+
+*/

0 comments on commit 6ecb498

Please sign in to comment.