npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

node-red-contrib-simple-webdriver

v0.4.3

Published

SimpleWebdriver nodes for Node-RED initially based on node-red-contrib-selenium-wd2

Downloads

101

Readme

node-red-contrib-simplewebdriver

Coverage Status npm Libraries.io dependency status for latest release

Simplewebdriver nodes for Node-Red allow web browser automation initially based on the Selenium-Webdriver API. Based on node-red-contrib-selenium-webdriver library and forked from node-red-contrib-selenium-wd2, it was rewritten in Typescript to ease its maintenance, improve the overall stability and upgrade a little bit the set of features.

simple-webdriver workflow example

Prerequisite

In order to use node-red-contrib-simple-webdriver, you must fullfill the following prerequisite :

  • Install a webdriver server : npm install -g chromedriver (can be replaced with geckodriver, edgedriver, safaridriver)
  • Install a node-red server : npm install -g --unsafe-perm node-red

Installation

  • Install node-red-contrib-simple-webdriver library : npm install -g node-red-contrib-simple-webdriver and that's all!

Run

Launch Node-red node-red and the simplewebdriver nodes will be loaded automatically. You should see the list of node under the simplewebdriver section.

simplewebdriver section overview

Behavior

Create a new flow

You will always have to start with an open-browser node.

Most of the nodes will provide two outputs a success and a failure one.

  • Success output is used if the node execution is successful and if the flow execution can continue (i.e. the driver is still ok)
  • Failure ouput is used in case of "soft" error (an element can't be found or an expected value is not correct). It aims to support dysfonctional use cases. (If something can't be clicked or found)
  • Error is launched in case of "critical" error (i.e. the driver can't be used anymore). It means you will have to handle yourselft the cleaning on the simple-webdriver side in this case.

Mustache support for node properties

Most of the nodes' properties support simplified mustache syntax to retrieve value directly from the msg object (e.g. {{msg.property}}) or the environment (e.g. {{env.property}})

Documentation

All nodes provides their own documentation directly inside node-red.

swd help overview

Develop

If you want to contribute, you can install clone the project and run the following command :

  • npm run clean && npm run prepublishOnly

To test it, you will have to :

  • Install a node-red locally (in another folder) npm install -g node-red

  • Launch, from the node-red folder, the following command to debug :

    npm install [PATH_TO_CONTRIB_SIMPLEWEBDRIVER] && node --inspect node_modules/node-red/red.js