Menu

1 / 4

Koa Js : Part 1 - How to make a Koa server in 10 minutes!

DEV Community: koa·Kachi Cheong·8 months ago
#YBdi4TOC
#devtokoa#devto#dev#router#exit
Long article (1311 words) — no AI summary yet.
Reading 0:00
15s threshold

Koa Js is a web framework designed by the team behind Express , which aims to be a smaller, more expressive, and more robust foundation for web applications and APIs.

In this tutorial, we'll be making a Koa Js server from scratch using Node Js .

Installation

In order to follow this tutorial you will need to have Node installed - ideally at the LTS (long term support) version.

Run the following command in your terminal to check if you have Node installed:

node --version

Enter fullscreen mode

Exit fullscreen mode

In this tutorial, I will be using Visual studio code as the text editor and Postman for the HTTP requests , but feel free to use whichever tools you want.

Set up

Let's start by running the following commands:

mkdir koa_tutorial cd koa_tutorial npm init -y

Enter fullscreen mode

Exit fullscreen mode

What did we just do?

Created a directory called koa_tutorial .

Inside our koa_tutorial directory we should have a file named package.json with default values.

Now we have our package.json…

Continue reading — create a free account

Join HashtagPLUS to read full articles, follow hashtags, vote, and join the conversation.