Skip to content

Just a basic web server written in dart. It has a simple controller that responds with an ok response, and a second port serves up static sites if there is one in the correct folder.

Notifications You must be signed in to change notification settings

posthello-code/dart-server

Repository files navigation

Tempalate for a REST API server or a static site server

Installation

You will need to have dart installed https://dart.dev/get-dart

Running the server

dart run

Running tests

dart test

REST Server

There is a simple controller that responds on the "/" request with a string response on port 4001

Static Site Server

Static site is served up on port 4002. Put a static site in the build/web folder and it will be served up on port 4002 if it has an index.html file.

About

Just a basic web server written in dart. It has a simple controller that responds with an ok response, and a second port serves up static sites if there is one in the correct folder.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published