Javascript Validator in Designer

Hi,

I’ve posted about this before and didn’t get a a response, but have just run into this again so thought I’d try another post. Can anyone explain why Javascript validation doesn’t work in Javascript Script Libraries?

I’d gotten round this problem by using File Resources to write Javascript and managing to get a JSLint validator installed, but now I’d like to start working with XPages and have found that you can only use javascript files set up as Script Libraries, not ones created a file resources.

I’m testing whether validation works like this: in my preferences - Javascript\Validator\Errors/Warnings - I’ve got optional semi-colon set to ‘Warning’. I create a js script library, write a simple function like this:

function whatever() {

x = 1

}

and save. No warning anywhere. No option to right-click - Validate or any way I can see of setting the validation off.

Am I missing something here? Having a validator is such a timesaver that it’s taking a big step backwards to have to start working without one, and it’s really depressing to see those options in the preferences but not to be able to take advantage of them.

Thanks,

Emily.

Subject: there are two client JS editors available in designer

the one used by default for client js libs is an older one (we are looking to change this soon). You can use the newer JS editor (the one which surfaces the preferences you set), by enabling Window/Show View/General/Navigator, and then right clicking on the .js file to open with the JavaScript editor. This will use the editor you are looking for.

Subject: Re: there are two client JS editors available in designer

Thanks for the response - that’s great news. Unfortunately, validation doesn’t seem to be working in the JS Editor either. Same test conditions - right click/Validate states that the validation completed with no warnings or errors.

It doesn’t seem as though Templates or Save actions are working either. Could this be down to a misconfiguration of my Designer client? Has anyone actually got these features working?

Thanks,

Emily

Subject: if there’s misconfiguration

it’s probably Designer itself, not your specific client. We’ll investigate what’s going on here!

Subject: Suggestion

Have you tried to include in the include path? From the preferences go to Javascript->Include Path->User Libraries