Get started with node-open CDN
MIT licensed
Node-open: Parse, manipulate XML/HTML in Node.js.
Tags:- app
- open
- opener
- opens
- launch
- start
- xdg-open
- xdg
- default
- cmd
- browser
- editor
- executable
- exe
- url
- urls
- arguments
- args
- spawn
- exec
- child
- process
- website
- file
Stable version
Copied!
How to start using node-open CDN
const { open } = require('https'); // For making HTTP requests
const NodeOpen = require('https://cdn.cdnhub.io/node-open/10.1.0/index.js').default;
const url = 'https://example.com';
const nodeOpenInstance = new NodeOpen();
nodeOpenInstance.open(url, (error, win) => {
if (error) {
console.error('Error opening URL:', error);
return;
}
// Perform any necessary actions on the new BrowserWindow instance
win.on('closed', () => {
console.log('Browser window closed.');
});
});
Copied!
Copied!
Copied!