mirror of
				https://github.com/LadybirdBrowser/ladybird.git
				synced 2025-10-31 13:20:59 +00:00 
			
		
		
		
	LibWeb: Implement enough HTML parsing to handle a small simple DOM :^)
We can now parse a little DOM like this:
<!DOCTYPE html>
<html>
    <head></head>
    <body>
        <div></div>
    </body>
</html>
This is pretty slow work, but the incremental progress is satisfying!
			
			
This commit is contained in:
		
							parent
							
								
									fd1b31d0ff
								
							
						
					
					
						commit
						e44c87cfff
					
				
				
				Notes:
				
					sideshowbarker
				
				2024-07-19 06:12:00 +09:00 
				
			
			Author: https://github.com/awesomekling
Commit: e44c87cfff
			
					 5 changed files with 110 additions and 6 deletions
				
			
		|  | @ -74,6 +74,9 @@ | |||
| #define ANYTHING_ELSE if (1) | ||||
| 
 | ||||
| #define EMIT_EOF                                  \ | ||||
|     if (m_has_emitted_eof)                        \ | ||||
|         return {};                                \ | ||||
|     m_has_emitted_eof = true;                     \ | ||||
|     create_new_token(HTMLToken::Type::EndOfFile); \ | ||||
|     return m_current_token; | ||||
| 
 | ||||
|  | @ -775,7 +778,7 @@ void HTMLTokenizer::will_reconsume_in([[maybe_unused]] State new_state) | |||
| void HTMLTokenizer::flush_current_character_or_comment_if_needed() | ||||
| { | ||||
|     //if (m_current_token.type() == HTMLToken::Type::Character || m_current_token.type() == HTMLToken::Type::Comment)
 | ||||
| //        emit_current_token();
 | ||||
|     //        emit_current_token();
 | ||||
| } | ||||
| 
 | ||||
| } | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Andreas Kling
						Andreas Kling