Research
Security News
Malicious npm Package Targets Solana Developers and Hijacks Funds
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
nightmare-window-manager
Advanced tools
Add window management to your Nightmare scripts.
Simply require the library:
var Nightmare = require('nightmare')
require('nightmare-window-manager')(Nightmare)
... and then enable the window manager with .windowManager()
. It should be the first call in your Nightmare chain.
Sets up window management.
Gets a listing of the windows currently open under the Nightmare instance.
Waits for all of the windows to no longer be in a loading state.
Gets the current window.
Closes the window specified by the window ID. If the current window is the one being closed, the first non-closed window is set as focused. WARNING: do not close the ID 1 as that will dispose the Nightmare plumbing.
Sets the given window ID as focused.
Invokes fn
on the currently selected window with the arguments supplied. All of the arguments are optional. On completion, it returns the return value of fn
, same as Nightmare's .evaluate()
.
var Nightmare = require('nightmare');
require('nightmare-window-manager')(Nightmare);
var nightmare = Nightmare();
nightmare
.windowManager()
.goto(url)
.click('#something_opens_a_window')
.waitWindowLoad()
.currentWindow()
.then(function(window){
//window contains useful information about the newly-opened window,
//including the window ID
console.dir(window)
});
FAQs
add window management to your Nightmare scripts
We found that nightmare-window-manager 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.
Research
Security News
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
Security News
Research
Socket researchers have discovered malicious npm packages targeting crypto developers, stealing credentials and wallet data using spyware delivered through typosquats of popular cryptographic libraries.
Security News
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.