Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / pas2js / 2019-06

Pas2js libjquery typos?

2 messages · 2 people · –

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Macfly

Hello,

In the Object declaration:
TJQuery = class external name 'JQuery' (TJSObject)

Should not the correct name be jQuery (with j minuscule)?

Because JQuery (with capital J) does not exist in the javascript context.

So if I need to access a static method like:

Pascal:
TJQuery.getJSON()

This is transcripeted to JS as:
JQuery.getJSON()

Which obviously fails.
Expected are jQuery.getJSON()

Another issue. In line 442 the function exports JQuery with j in capital:
Function JQuery(Const aElement : Array of TJSElement) : TJQuery; external
name 'JQuery';

Best regards!

Reply by email

Michael Van Canneyt
to Macfly

Hello,

You are right.

I fixed the case in these 2 cases.

Michael.

PS. If you want to write to the mailing list, you must subscribe yor email address, see the URL at the bottom.

Macfly wrote 35 lines
Hello, In the Object declaration: TJQuery = class external name 'JQuery' (TJSObject) Should not the correct name be jQuery (with j minuscule)? Because JQuery (with capital J) does not exist in the javascript context. So if I need to access a static method like: Pascal: TJQuery.getJSON() This is transcripeted to JS as: JQuery.getJSON() Which obviously fails. Expected are jQuery.getJSON() Another issue. In line 442 the function exports JQuery with j in capital: Function JQuery(Const aElement : Array of TJSElement) : TJQuery; external name 'JQuery'; Best regards! -- Sent from: http://pas2js.38893.n8.nabble.com/ _______________________________________________ Pas2js maillist - https://lists.freepascal.org/cgi-bin/mailman/listinfo/pas2js

Reply by email