A todo app using [PlastronJS](https://github.com/rhysbrettbowen/PlastronJS)
and [Closure Tools](https://developers.google.com/closure/)
## Run
Just open the index.html in your browser
## Run uncompiled
The app is built with [Plovr](http://plovr.com/). To run the unminified version you need to [download Plovr](http://plovr.com/download.html), create a directory called "build" and put the jar file in the build folder.
You will then need to [download PlastronJS](https://github.com/rhysbrettbowen/PlastronJS) to js/lib (you will need to create the folder).
Next open a command prompt in the base directory of the plastronjs todomvc example and type in.
```
java -jar build/plovr.jar serve plovr.json
```
Change the script src at the bottom of the index.html from js/compiled.js to:
```
http://localhost:9810/compile?id=todomvc&mode=raw
```
You can now view the uncompiled example and play around with it!
# Compilation
Once you have done the steps above you can compile any changes you make by running the below command:
```
java -jar build/plovr.jar build plovr.json
```
and view the compiled version fo the page by changing the bottom script src back to js/compiled.
## Need help?
shoot me a quick message on [twitter](https://twitter.com/#!/RhysBB)
## Credit
Created by [Rhys Brett-Bowen](http://rhysbrettbowen.com)
<p>Created by <ahref="http://rhysbrettbowen.com">Rhys Brett-Bowen</a> (<ahref="https://twitter.com/#!/RhysBB">RhysBB</a>).</p>
<p>Using <ahref="https://github.com/rhysbrettbowen/PlastronJS">PlastronJS</a> and <ahref="https://developers.google.com/closure/">Closure Tools</a></p>
<p>Part of <ahref="http://todomvc.com">TodoMVC</a>.</p>
n.start=function(){this.enabled=j;this.e||(this.e=this.ba.setTimeout(this.va,this.U),this.Ba=ja())};n.stop=function(){this.enabled=m;this.e&&(this.ba.clearTimeout(this.e),this.e=k)};n.d=function(){Vb.j.d.call(this);this.stop();deletethis.ba};varXb="tick";functionX(a){this.sb=a;this.Aa=[]}y(X,N);varYb=[];functionZb(a,b,c,d,e){r(c)||(Yb[0]=c,c=Yb);for(varf=0;f<c.length;f++)a.Aa.push(T(b,c[f],d||a,e||m,a.sb||a));returna}function$b(a){B(a.Aa,Jb);a.Aa.length=0}X.prototype.d=function(){X.j.d.call(this);$b(this)};X.prototype.handleEvent=function(){g(Error("EventHandler.handleEvent not implemented"))};functionac(){O.call(this,"navigate")}y(ac,O);functionY(a,b,c,d){a&&!b&&g(Error("Can't use invisible history without providing a blank page."));vare;c?e=c:(e="history_state"+bc,document.write(ka(cc,e,e)),e=M(e));this.ia=e;this.c=c?L(c)?L(c).parentWindow||L(c).defaultView:window:window;this.lb=this.c.location.href.split("#")[0];this.ja=b;F&&!b&&(this.ja="https"==window.location.protocol?"https:///":'javascript:""');this.e=newVb(dc);this.R=!a;this.D=newX(this);if(a||F&&!ec)d?a=d:(a="history_iframe"+bc,b=this.ja?'src="'+na(this.ja)+'"':"",document.write(ka(fc,
pc.prototype.yb=function(){vara=this.T.s();B(this.ab||[],function(b){varc=b.$.exec(a);c&&b.mb.apply(this,c)},this)};functionqc(){}(function(a){a.Ra=function(){returna.ub||(a.ub=newa)}})(qc);qc.prototype.xb=0;qc.Ra();functionrc(a){this.I=a||mb()}y(rc,U);n=rc.prototype;n.tb=qc.Ra();n.K=k;n.i=m;n.h=k;n.l=k;n.o=k;n.f=k;n.n=k;n.jb=m;functionsc(a){returna.K||(a.K=":"+(a.tb.xb++).toString(36))}n.w=function(){returnthis.h};functiontc(a,b){a==b&&g(Error("Unable to set parent component"));b&&a.o&&a.K&&a.o.n&&a.K&&a.Kina.o.n&&a.o.n[a.K]&&a.o!=b&&g(Error("Unable to set parent component"));a.o=b;rc.j.Ga.call(a,b)}n.getParent=function(){returnthis.o};
n.Ga=function(a){this.o&&this.o!=a&&g(Error("Method not supported"));rc.j.Ga.call(this,a)};n.xa=function(){this.h=this.I.createElement("div")};n.C=function(){this.i=j;uc(this,function(a){!a.i&&a.w()&&a.C()})};functionvc(a){uc(a,function(a){a.i&&vc(a)});a.J&&$b(a.J);a.i=m}n.d=function(){rc.j.d.call(this);this.i&&vc(this);this.J&&(this.J.k(),deletethis.J);uc(this,function(a){a.k()});!this.jb&&this.h&&ub(this.h);this.o=this.l=this.h=this.n=this.f=k};functionuc(a,b){a.f&&B(a.f,b,i)}
n.removeChild=function(a,b){if(a){varc=u(a)?a:sc(a),a=this.n&&c?(cinthis.n?this.n[c]:i)||k:k;c&&a&&(ib(this.n,c),Ba(this.f,a),b&&(vc(a),a.h&&ub(a.h)),tc(a,k))}a||g(Error("Child is not in parent component"));returna};n.$a=function(a){for(;this.f&&0!=this.f.length;)this.removeChild(this.f?this.f[0]||k:k,a)};functionZ(a){this.I=mb();this.l=a;this.r={Ca:{},F:{}};this.N=[]}y(Z,rc);n=Z.prototype;n.remove=function(){ub(this.w());this.k()};n.rb=function(a,b){this.r.F[a]&&B(this.r.F[a],function(a){b.H||(!a.bb.length||ua(a.bb,function(a){returnda(a)?a(b):yb(b.target,a)}))&&a.ha.call(a.S,b)})};
Ec.prototype.refresh=function(){uc(this,function(a){a.k()});this.$a(j);B(Ub(this.l,this.Qa),function(a){vara=newDc(a),b=this.f?this.f.length:0;a.i&&!this.i&&g(Error("Component already rendered"));(0>b||b>(this.f?this.f.length:0))&&g(Error("Child component index out of bounds"));if(!this.n||!this.f)this.n={},this.f=[];if(a.getParent()==this)this.n[sc(a)]=a,Ba(this.f,a);else{varc=this.n,d=sc(a);dinc&&g(Error('The object already contains the key "'+d+'"'));c[d]=a}tc(a,this);za(this.f,a,b);a.i&&
functionPc(a,b){b.push('"',a.replace(Rc,function(a){if(ainQc)returnQc[a];varb=a.charCodeAt(0),e="\\u";16>b?e+="000":256>b?e+="00":4096>b&&(e+="0");returnQc[a]=e+b.toString(16)}),'"')};functionSc(){};functionTc(a){this.Y=a;this.cb=newMc}n=Tc.prototype;n.Y=k;n.cb=k;n.set=function(a,b){q(b)?this.Y.set(a,Nc(this.cb,b)):this.Y.remove(a)};n.get=function(a){a=this.Y.get(a);if(a!==k)try{returnLc(a)}catch(b){g("Storage: Invalid value was encountered")}};n.remove=function(a){this.Y.remove(a)};functionUc(){}y(Uc,Sc);functionVc(a){this.pa=a}y(Vc,Uc);Vc.prototype.set=function(a,b){try{this.pa.setItem(a,b)}catch(c){g("Storage mechanism: Quota exceeded")}};Vc.prototype.get=function(a){a=this.pa.getItem(a);if(u(a)||a===k)returna;g("Storage mechanism: Invalid value was encountered")};Vc.prototype.remove=function(a){this.pa.removeItem(a)};functionWc(){vara=k;try{a=window.localStorage||k}catch(b){}this.pa=a}y(Wc,Vc);functionXc(){this.qa=newTc(newWc)}Xc.prototype.create=function(a){varb;this.Na=this.Na||0;b=this.Na+++"|"+parseInt((newDate).getTime(),36);a.set("id",b)};Xc.prototype.Za=function(a){a.set(this.qa.get(a.get("id")))};Xc.prototype.update=function(a){this.qa.set(a.get("id"),a.ra())};functionYc(){Xc.call(this)}y(Yc,Xc);Yc.prototype.Za=function(a){varb=this.qa.get(a.get("id"))||[];B(b,function(b){b=newa.Va(b);a.add(b,0,j)});a.u()};functionZc(a){V.call(this,a);Rb(this,function(a){a=la(a);a.length||g(newPb);returna});Tb(this,function(){this.k()})}y(Zc,V);function$c(){W.call(this,{id:"todos-plastronjs",sync:newYc,schema:{completed:{get:function(){returnUb(this,function(a){returna.get("completed")})},wb:j}},modelType:Zc})}y($c,W);$c.prototype.ra=function(){returnC(Ub(this),function(a){returna.ra()})};varad=new$c,Kc=newEc(ad),$=Kc,bd=M("todoapp");$.i&&g(Error("Component already rendered"));if(bd){$.jb=j;if(!$.I||$.I.B!=L(bd))$.I=mb(bd);$.h=bd;$.C()}elseg(Error("Invalid element to decorate"));varcd=newpc;
<ahref="architecture-examples/o_O/index.html"data-source="http://weepy.github.com/o_O/"data-content="o_O: HTML binding for teh lulz: <br>- Elegantly binds objects to HTML<br>- Proxies through jQuery, Ender, etc<br>- Automatic dependency resolution<br>- Plays well with others">Funnyface.js</a>
</li>
<li>
<ahref="architecture-examples/plastronjs/index.html"data-source="https://github.com/rhysbrettbowen/PlastronJS"data-content="PlastronJS is an mvc framework built on top of the Closure Library and built to compile with projects that use the Closure Compiler.">PlastronJS</a>