@skills17/static-task-server
TypeScript icon, indicating that this package has built-in type declarations

3.0.0 • Public • Published

skills17/static-task-server

Serves static task files.

Table of contents

Installation

npm install @skills17/static-task-server

Usage

A TaskConfig instance of the @skills17/task-config package can be passed to the Server constructor.

import Server from '@skills17/static-task-server';

const server = new Server(taskConfig);
await server.serve();

This will start a static file server on the address and port specified in the task configuration. The address under which the task is reachable will be printed to the console. To disable the console output, pass false as a parameter to the serve method.

Later, the server can be stopped again by calling the stop method:

await server.stop();

License

MIT

Readme

Keywords

none

Package Sidebar

Install

npm i @skills17/static-task-server

Weekly Downloads

0

Version

3.0.0

License

MIT

Unpacked Size

7.35 kB

Total Files

7

Last publish

Collaborators

  • cyrilwanner
  • skills17