Skip to content

AndrewJBateman/node-koa-data

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

⚡ Node Koa Data

  • Node.js used with Koa instead of Express middleware, with embedded javascript (EJS) & Bootstrap to display oil well data
  • Note: to open web links in a new window use: ctrl+click on link

GitHub repo size GitHub pull requests GitHub Repo stars GitHub last commit

📄 Table of contents

📚 General info

  • Koa middleware used to add routing, body-parser, JSON and EJS HTML views
  • Simple Bootstrap navbar
  • An oil well name can be added to the list - this is not stored in a database and will be lost when app is shut down.

📷 Screenshots

Image

📶 Technologies

💾 Setup

  • npm i to install dependencies
  • npm run dev runs app in the development mode with auto-restart.
  • Open http://localhost:5000 to view in the browser.

🔧 Testing

  • N/A

💻 Code Examples

  • index.js asynchronous function to render the index page in the browser root using Koa middleware
router.get("/", async (ctx) => {
  await ctx.render("index", {
    title: "Underground Injection Control Wells",
    wells: wells,
  });
});

🆒 Features

  • Uses Koa which is much lighter than the usual Express middleware

📋 Status, Testing & To-Do List

  • Status: Working
  • To-Do: Add well update and delete + database connection & other db fields such as location of well etc.

👏 Inspiration

📁 License

  • This project is licensed under the terms of the MIT license.

✉️ Contact

About

📋 Node.js used with Koa instead of Express middleware, with embedded javascript (EJS) & Bootstrap to display oil well data

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published