In this final chapter, I want to take you somewhere very different—to give you a peek into the future of Node.js programming. You may be surprised at what you see!
Rather than composing JavaScript in a text editor, here you’ll learn how to use a visual editor called Node-RED.[108] Originally developed by IBM and now stewarded by the JS Foundation,[109] Node-RED bills itself as “a visual tool for wiring the Internet of Things.” But it can do way more than that.
I like to think of Node-RED as a visual IDE, specially tuned for creating asynchronous, event-driven Node.js programs. With Node-RED, you drag and drop nodes—units of functionality—and connect them via their input and output ports. A node in Node-RED is a waypoint that produces, consumes, or transforms events as they flow through the system. This allows you to literally see how events will flow through your program.
You’ll learn how to create an HTTP API using Node-RED without writing any JavaScript. (Well, maybe just a little.) We’ll plug into Elasticsearch, like in previous chapters, but you can use the same techniques to connect to any RESTful web service.
By the end of the chapter, you should be comfortable enough with Node-RED to use it to develop your own flows from scratch. I hope you’ll find it as enjoyable to use as I do!
Now let’s get started with Node-RED by installing and configuring it for local development.