Not logged in.  Login/Logout/Register | List snippets | | Create snippet | Upload image | Upload data

13
LINES

< > BotCompany Repo | #1031614 // allJavascriptFromHTMLIncludingEventHandlers

JavaX fragment (include) [tags: use-pretranspiled]

Libraryless. Click here for Pure Java version (5324L/33K).

1  
static LS allJavascriptFromHTMLIncludingEventHandlers(S html) {
2  
  ret allJavascriptFromHTMLIncludingEventHandlers(htmlTok(html));
3  
}
4  
5  
static LS allJavascriptFromHTMLIncludingEventHandlers(LS tok) {
6  
  LS list = allJavascriptFromHTML(tok);
7  
    
8  
  for (S tag : codeTokens(tok))
9  
    for (S key, S value : tagParams(tag))
10  
      if (swic(key, "on")) list.add(value);
11  
      
12  
  ret list;
13  
}

Author comment

Began life as a copy of #1031449

download  show line numbers  debug dex  old transpilations   

Travelled to 4 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx, vouqrxazstgt

No comments. add comment

Snippet ID: #1031614
Snippet name: allJavascriptFromHTMLIncludingEventHandlers
Eternal ID of this version: #1031614/3
Text MD5: 757461241d7adf623faffc05fb8e8989
Transpilation MD5: 60d67a938b33137e28bbf9f70b0b5e6c
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2021-06-22 11:10:20
Source code size: 392 bytes / 13 lines
Pitched / IR pitched: No / No
Views / Downloads: 190 / 245
Version history: 2 change(s)
Referenced in: [show references]