
Security News
Insecure Agents Podcast: Certified Patches, Supply Chain Security, and AI Agents
Socket CEO Feross Aboukhadijeh joins Insecure Agents to discuss CVE remediation and why supply chain attacks require a different security approach.
abstract-browser
Advanced tools
Interface for opening and closing a browser. Uses nanoresource for state management, browser-manifest for metadata. Pairs well with browser-provider.
With promises:
const Browser = require('abstract-browser').promises
class MyBrowser extends Browser {
async _open () {
// open the browser
console.log('opening', this.target.url)
}
async _close () {
// close the browser
}
}
With callbacks:
const Browser = require('abstract-browser')
class MyBrowser extends Browser {
_open (callback) {
// ..
}
_close (callback) {
// ..
}
}
browser = new Browser(manifest, target)Constructor. Takes a browser-manifest and a target object in the form of { url }.
Implementors are free to change the signature of their constructor. User-facing options specific to an implementation should be passed in via manifest.options.
browser.open([callback])Open the browser. Returns a promise if no callback is provided.
browser.close([callback])Close the browser. Returns a promise if no callback is provided.
browser.status(ok[, callback])Set status by a boolean ok. Returns a promise if no callback is provided. Useful for remote browsers like Sauce Labs where you can set the remote job status e.g. after running tests on a browser.
browser.manifestThe manifest that was passed to the constructor.
browser.targetThe target that was passed to the constructor.
Browsers may emit error events. It's recommended to only do so after open() has completed and not after close() has been called. The transient-error module may be used to signal that the error is temporary and that running (a new instance of) the browser can be retried.
With npm do:
npm install abstract-browser
MIT © 2020-present Airtap contributors
FAQs
Interface for opening and closing a browser
We found that abstract-browser demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
Socket CEO Feross Aboukhadijeh joins Insecure Agents to discuss CVE remediation and why supply chain attacks require a different security approach.

Security News
Tailwind Labs laid off 75% of its engineering team after revenue dropped 80%, as LLMs redirect traffic away from documentation where developers discover paid products.

Security News
The planned feature introduces a review step before releases go live, following the Shai-Hulud attacks and a rocky migration off classic tokens that disrupted maintainer workflows.