Skip to content

IainIsCreative/simple-nodebot

Repository files navigation

Simple Nodebot with JavaScript

This is the full code for the Simple Nodebot for the JavaScript with Hardware. This includes the code for Arduino, a simple web interface, and a node server. If you're stuck with the code, feel free to use as a reference!

Installation

To install dependencies, simple install via NPM.

npm install

Alternatively, you can use Yarn. I personally prefer Yarn.

yarn install

Commands and Scripts

This Nodebot has a set of scripts for development and production uses. Simply use node or yarn to run them.

  • start — Starts the development server on port 8000 using babel-node.
  • dev — Starts Webpack and watches for changes in browser.js.
  • build — Makes a compiled copy of the browser and server code.
  • test — Tests all scripts using ESLint and Flow. (Note: uses Yarn to run command).
  • production — Runs the compiled server code.

Having Trouble?

Feel free to open an issue! Hopefully you won't have any problems, but be sure to file any issues that may arise.

Support The Author!

Do you enjoy the JavaScript with Hardware series? Feel free to support me by following me on Twitter and subscribe to my mailing list to get updates!