node-red-contrib-string

272 views
Skip to first unread message

Stephen J Carnam

unread,
Oct 2, 2017, 2:31:22 AM10/2/17
to Node-RED
Just released my first Node-RED Contrib (be kind). It's a for a basic string object (with bonus extras). I've written and used the virtually identical string parsing functions in JavaScript, Lingo, Perl, PHP, VisualBasic, etc. While it's not rocket science and I've noticed many have written similar, I've decided to adopt & combine it with the open source stringjs project. My fork has then been wrapped up with some Node-RED UI magic, documentation, and examples and furnished to npm. The GitHub project (with screenshots that render in the readme markdown) can be found at:


Please consider star'ing it if you like it! I wish it were apart of Node-RED's core palette. :)

Regards,
Stephen

Dave C-J

unread,
Oct 2, 2017, 4:58:47 AM10/2/17
to node...@googlegroups.com
Nice - is there a license to go with it ? Also you say to install under the Node-RED root directory… - normally we suggest this is a bad idea and users should install under their user directory  usually ~/.node-red

damo....@gmail.com

unread,
Oct 2, 2017, 5:53:36 AM10/2/17
to Node-RED
Congrats on publishing your first node Stephen. :)

string looks really useful, especially in combination with the change node.

I'm not familiar with stringjs but after a quick search, it appears it doesn't do regular expressions.  Please correct me if I am wrong.  Otherwise, it would be really neat if that was something you could add to the node.  Would round out the node's functionality nicely as a bit of a catch all.

Of course REs aren't for everyone ;)

Damo.

Dave C-J

unread,
Oct 2, 2017, 8:55:23 AM10/2/17
to node...@googlegroups.com
Well you have the change node to do Regex already... - better to keep this focussed on simplicity and compatibility with stringjs I think... but then again... it's not my node :-)

Julian Knight

unread,
Oct 2, 2017, 11:13:05 AM10/2/17
to Node-RED
I can see both sides of that argument. I have to say that regex was my first thought too. I love the fact that this is focused on a single attribute which makes the chained transforms simpler to think and reason about.

Not too big a deal either way. As I mentioned in the slack, I think this will be going in my Awesome list of Node-RED nodes after I've given it a bit of a work out :-)

I did raise an issue about the installation instructions.

Jan Van den Audenaerde

unread,
Oct 2, 2017, 2:40:06 PM10/2/17
to Node-RED
Looks indeed an interested string parsing node.
Nice job.  Need to check this out.
kr
Jan

Stephen J Carnam

unread,
Oct 2, 2017, 8:07:48 PM10/2/17
to Node-RED
Package indicates license as MIT. Updated install suggestion to user directory. Thanks for the feed back!
Reply all
Reply to author
Forward
0 new messages