node-red-contrib-get-hrefs

A Node-RED node to get all href urls from an HTML string

Downloads in past

Stats

StarsIssuesVersionUpdatedCreatedSize
node-red-contrib-get-hrefs
2.1.08 years ago8 years agoMinified + gzip package size for node-red-contrib-get-hrefs in KB

Readme

node-red-contrib-get-hrefs
!Build statustravis-imagetravis-url !NPM versionnpm-imagenpm-url !XO code stylecodestyle-imagecodestyle-url
A Node-RED node to get all href urls from an HTML string

A node that extracts all <a href=""> targets from payload in the input message and attaches them as an array hrefs on the output message.

Installation

Install node-red-contrib-get-hrefs using npm:
npm install --save node-red-contrib-get-hrefs

Usage

To use the node, launch Node-RED (see running Node-RED for help getting started).
The input payload should be the HTML to get hrefs from.
If the input message contains a url property it will be used as the baseUrl option for get-hrefs under the hood.
The output message will be the same as the input but with an hrefs array containing all found href urls in the HTML body.

Icon credit

The node icon is the link-variant icon from Material Design Icons by Austin Andrews @Templarian.

License

MIT © Joakim Carlstein