Uncaught ReferenceError: $ is not defined

74 views
Skip to first unread message

Kevin Crowell

unread,
Feb 17, 2015, 12:21:54 PM2/17/15
to cefs...@googlegroups.com
I am trying to run the WpfExample out-of-the-box. Everything compiles and runs fine. However, when I try to execute the javascript, I am getting an "Uncaught ReferenceError: $ is not defined" error.

Obviously, jquery does not seem to be hooked into the BindingTest.html correctly. I see that it is included in the resources. Any idea why it is not working? I assume I can add jquery as a script at the top of BindingTest.html, but I'd rather have it work as it was originally set up.

Jørn Hansen

unread,
Feb 17, 2015, 6:42:34 PM2/17/15
to cefs...@googlegroups.com
Looks like you're right. The JavaScript execution thing got broken I think when to original pretty Bootstrap+jQuery etc. home page got replaced with the `bindingTest.html` in celebration of that the JSBinding got to a functional state around here: https://github.com/cefsharp/CefSharp/commit/f55060a947f79dd2136536cd8ec2f9017ce08a27#diff-8504643e16a7bcd2d9428f463a767ff9L7

I guess the proper fix would be to make room for both with the original home page as the first tab with UI on the side and BindingTest.html as a second tab - or maybe to keep it super-simple just navigation to it. A PR is welcome :-) Sounds like a good beginners project for anyone wanting to dabble a bit in the CefSharp example applications.

Kevin Crowell

unread,
Feb 17, 2015, 6:58:58 PM2/17/15
to cefs...@googlegroups.com
Oh I see. It looks like the sidebar was designed for home.html, not BindingTest.html. Yea, I could make a change where it starts with 2 tabs like you said. The sidebar would only be attached to home.html, but not BindingTest.html. Do you think that would be preferred?

Jørn Hansen

unread,
Feb 18, 2015, 11:50:27 AM2/18/15
to cefs...@googlegroups.com
Yep, sounds right to me!
Reply all
Reply to author
Forward
0 new messages