Basic

This is a basic boilerplate generated by the noonjs CLI after running

import Noonjs from "noonjs"
import config from "../config.json"

const noonjs = new Noonjs(config)

noonjs.on("error", error => {
    console.log(error)
})

noonjs.on("started", port => {
    console.log(`✅ Server is running on http://localhost:${port}`)
})

noonjs.start()

It loads the configuration from a JSON file, initializes the noonjs server, and sets up listeners to handle errors and log the server start message to the console. This is the default starting point for noonjs-based backend projects.

Edit this page on Github
© 2025 kav3.com. Crafted with and dedication.