Hello Tony, The repository is at https://github.com/angular/angular
Kind regards, Marwijn. 2014-11-04 17:34 GMT+01:00 Tony pee <[email protected]>: > which repo? link? (i just want to peruse, probably cant help) > > On 4 November 2014 00:49, Marwijn Christiaans < > [email protected]> wrote: > >> Hello All, >> >> I'm trying to get the Todo example in the angular 2.0 code working. >> I've tried the changes below. However it seems that App is not defined on >> appModule. As far as I can tell when debugging the execute function on the >> compiled app.js is not executed. >> Could anyone help me out to get the sample working ? >> >> Thanks, >> >> Marwijn. >> >> -------------- >> >> index.html: >> >> <!doctype html> >> <html> >> <body> >> <input type="test"> >> <ul></ul> >> >> <% if(type === 'dart') { %> >> <script src="main.dart" type="application/dart"></script> >> <% } else { %> >> >> <script src="../../../traceur-runtime.js" >> type="text/javascript"></script> >> <script src="../../../es6-module-loader.src.js" >> type="text/javascript"></script> >> <script src="../../../extension-register.js" >> type="text/javascript"></script> >> <script type="text/javascript"> >> register(System); >> </script> >> <script src="../../../rtts_assert/lib/rtts_assert.js" >> type="text/javascript"></script> >> <script src="app.js" type="text/javascript"></script> >> <script src="../../../facade/lib/dom.js" >> type="text/javascript"></script> >> <script src="main.js" type="text/javascript"></script> >> <% } %> >> </body> >> </html> >> >> -------------------- >> >> main.es5: >> >> System.baseURL = '/'; >> >> System.import("examples/lib/todo/app") >> .then(function(appModule){ >> console.log("import done"); >> app = new appModule.App(); // App is undefined on appModule; >> console.log("will not get here"); >> }); >> >> ------------------ >> >> app.js >> >> import {DOM} from 'facade/dom'; >> >> export class App { >> constructor() { >> this.input = null; >> this.list = null; >> } >> run() { >> this.input = DOM.query('input'); >> this.list = DOM.query('ul'); >> DOM.on(this.input, 'change', (evt) => this.add(evt)); >> } >> add(evt) { >> var html = DOM.getInnerHTML(this.list); >> html += '<li>'+this.input.value+'</li>'; >> DOM.setInnerHTML(this.list, html); >> this.input.value = ''; >> } >> } >> >> -- >> You received this message because you are subscribed to the Google Groups >> "AngularJS" group. >> To unsubscribe from this group and stop receiving emails from it, send an >> email to [email protected]. >> To post to this group, send email to [email protected]. >> Visit this group at http://groups.google.com/group/angular. >> For more options, visit https://groups.google.com/d/optout. >> > > > > -- > Tony Polinelli > > -- > You received this message because you are subscribed to a topic in the > Google Groups "AngularJS" group. > To unsubscribe from this topic, visit > https://groups.google.com/d/topic/angular/WeCbKuJtsC4/unsubscribe. > To unsubscribe from this group and all its topics, send an email to > [email protected]. > To post to this group, send email to [email protected]. > Visit this group at http://groups.google.com/group/angular. > For more options, visit https://groups.google.com/d/optout. > -- You received this message because you are subscribed to the Google Groups "AngularJS" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/angular. For more options, visit https://groups.google.com/d/optout.
