This is an example of how to create a simple module for Node.js. It is used in Chapter 22 of the Sams Teach Yourself Node.js in 24 Hours book.
The module only has one function - hello()
. This returns "Hello from the ohaithere module".
The examples shows:
- How to create a module with Node.js
- How to write a simple test for the module
- Adding a README file
- Adding a LICENSE file
- How to hook the module up to Travis CI
- How to create a package.json file