davidsalter.uk - Thoughts on Java, Web Development, and anything to do with braces {}.


  • Autorestarting Node.js apps during development

    When writing a Node.js application, it’s frustrating to have to start and stop the application whenever changes are made. To allow us to develop more efficiently, we need something that monitors our Node.js application directory and restarts the application whenever changes are made.

  • Reading a configuration file in NodeJS

    Using NodeJS, its easy to read a configuration file using the fs module. To read a configuration file, we need to include the fs module, read in the configuration file and then parse it from JSON into a JavaScript variable. Given the following configuration file (configuration.json):

  • Hello World! in Node.js

    As is usual in computer programming, when learning a new language or framework, the initial program is the “Hello World!” application.