mirror of
				https://github.com/go-gitea/gitea
				synced 2025-11-03 21:08:25 +00:00 
			
		
		
		
	* rework eslint config - use explicit config that only enables rules - upgrade eslint to 7.1.0 - add new plugins with selected rules enabled - fix discovered issues, remove global wipPrefixes * remove if * undo template change * add disabled rules as well for easier config updating * add missing disabled rule * update eslint and plugins * fix new violation * remove deprecated rules Co-authored-by: Lauris BH <lauris@nix.lv>
		
			
				
	
	
		
			13 lines
		
	
	
		
			371 B
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
			
		
		
	
	
			13 lines
		
	
	
		
			371 B
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
import {highlightBlock} from 'highlight.js';
 | 
						|
import {createWindow} from 'domino';
 | 
						|
 | 
						|
self.addEventListener('message', ({data}) => {
 | 
						|
  const window = createWindow();
 | 
						|
  self.document = window.document;
 | 
						|
 | 
						|
  const {index, html} = data;
 | 
						|
  document.body.innerHTML = html;
 | 
						|
  highlightBlock(document.body.firstChild);
 | 
						|
  self.postMessage({index, html: document.body.innerHTML});
 | 
						|
});
 |