import {program} from "witheve"

81 views
Skip to first unread message

Felix George

unread,
May 14, 2017, 11:23:06 AM5/14/17
to Eve talk
I am attempting to use the Eve DSL with a WinJS project and have followed the directions to include code below:

import {Program} from "witheve";

let program = new Program("my program");
let htmlWatcher = program.attach("html");

let someElement = document.querySelector("#eve-wrapper");
htmlWatcher.addExternalRoot("my-root", someElement);
 



I have a div in my index.html with the id "eve-wrapper".... Is there anything else special that must be going on to get this started.  My javascript is inline in the html file.  Please advise.  Thanks.

Brian Theado

unread,
May 14, 2017, 9:20:56 PM5/14/17
to Felix George, Eve talk
One gotcha to watch out for as described at
https://github.com/witheve/Eve/issues/817#issuecomment-296387532 ...
make sure all bind calls come before the call to addExternalRoot. Not
sure if that is your issue.
> --
> You received this message because you are subscribed to the Google Groups
> "Eve talk" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to eve-talk+u...@googlegroups.com.
> To post to this group, send email to eve-...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/eve-talk/446f510e-f0c8-4eb0-9d40-4f0d27e561ca%40googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

Felix George

unread,
May 15, 2017, 8:00:57 PM5/15/17
to Eve talk
Regardless of where I put the addexternalroot call, Eve fails to add objects to the div container. 

Felix George

unread,
May 15, 2017, 8:32:16 PM5/15/17
to Eve talk
I had to add this line to get it working:
import "witheve-watchers/html"

and add alias to webpackconfig after checking out your files:
alias: {

      "witheve-watchers": "witheve/build/src/watchers"

    }

On Sunday, May 14, 2017 at 10:23:06 AM UTC-5, Felix George wrote:

Felix George

unread,
May 15, 2017, 8:34:05 PM5/15/17
to Eve talk
Thanks Brian...btw.  One step closer to world domination with Eve 👍


On Sunday, May 14, 2017 at 10:23:06 AM UTC-5, Felix George wrote:
Reply all
Reply to author
Forward
0 new messages