Libraryless. Click here for Pure Java version (5736L/36K).
svoid test_autoLoadJQuery() { S html = hjs("$('bla').bla();"); assertFalse(jqueryLoaded(html)); assertTrue(html, neq(autoLoadJQuery(html), html)); html = hjs("document.bla();"); assertEqualsVerbose(html, autoLoadJQuery(html)); html = hbutton("bla", onclick := "$(this).hide();"); assertTrue(html, neq(autoLoadJQuery(html), html)); }
download show line numbers debug dex old transpilations
Travelled to 4 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx, vouqrxazstgt
No comments. add comment
Snippet ID: | #1031456 |
Snippet name: | test_autoLoadJQuery |
Eternal ID of this version: | #1031456/5 |
Text MD5: | 011b628dd35c650efd5f991644fd7aa2 |
Transpilation MD5: | 6e78e1ce092c19d1fd1d6a2aad2f4244 |
Author: | stefan |
Category: | javax |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2021-06-22 05:20:00 |
Source code size: | 354 bytes / 9 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 176 / 280 |
Version history: | 4 change(s) |
Referenced in: | #1006654 - Standard functions list 2 (LIVE, continuation of #761) |