[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
[
List Home]
Re: [orion-dev] JavaScript editor: 'window' is not defined
|
Hi, Jon, welcome to Orion!
As far as the error checking goes, that is the jslint plug-in complaining about your use of globals.
See http://www.jslint.com/lint.html for a complete description of what jslint complains about and why.
You can tell jslint to ignore certain globals by listing them in a comment whose first token is "global." Like this:
/*global window */
This comment goes at the top of your source file. There are other jslint configuration properties that you can set up as needed. The doc above explains what options are available.
susan
Jon Kleiser ---03/22/2011 04:57:07 AM--- Hi, In my very first test of the code editor at orionhub.org, I entered
From: Jon Kleiser <jon.kleiser@xxxxxxxxxxx>
To: <orion-dev@xxxxxxxxxxx>
Date: 03/22/2011 04:57 AM
Subject: [orion-dev] _javascript_ editor: 'window' is not defined
Sent by: orion-dev-bounces@xxxxxxxxxxx
Hi,
In my very first test of the code editor at orionhub.org, I entered
this line ...
window.alert("hello!");
... and saved it as hello.js. I then got a red error icon to the left
of this line saying "'window' is not defined." If I changed it to ...
alert("hello!");
... and saved it, I got "'alert' is not defined."
I don't think these lines should be flagged as errors. ;-)
/Jon
_______________________________________________
orion-dev mailing list
orion-dev@xxxxxxxxxxx
http://dev.eclipse.org/mailman/listinfo/orion-dev