* docs: modernize protocol-handler docs * docs: iadd contextIsolation * docs: add guide for launch-app-from-URL-in-other-app * docs: address comments * chore: fix brackets * chore: add escaped brackets
		
			
				
	
	
		
			11 lines
		
	
	
		
			No EOL
		
	
	
		
			351 B
			
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
			
		
		
	
	
			11 lines
		
	
	
		
			No EOL
		
	
	
		
			351 B
			
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
// All of the Node.js APIs are available in the preload process.
 | 
						|
// It has the same sandbox as a Chrome extension.
 | 
						|
const { contextBridge, ipcRenderer } = require('electron')
 | 
						|
 | 
						|
// Set up context bridge between the renderer process and the main process
 | 
						|
contextBridge.exposeInMainWorld(
 | 
						|
  'shell',
 | 
						|
  {
 | 
						|
    open: () => ipcRenderer.send('shell:open'),
 | 
						|
  }
 | 
						|
) |