-
Notifications
You must be signed in to change notification settings - Fork 422
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use template literals + Move port to server block in config
- Loading branch information
Showing
4 changed files
with
31 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,22 +1,23 @@ | ||
// Configuration for the application | ||
export interface Config { | ||
// Server configuration | ||
server?: { | ||
// The port to run the HTTP server on | ||
// Default: 8080 | ||
port?: number; | ||
}; | ||
|
||
// Authentication configuration | ||
auth?: Auth; | ||
/** | ||
* The port to run the HTTP server on | ||
* @default 8080 | ||
*/ | ||
port?: number; | ||
} | ||
|
||
// Authentication settings | ||
export interface Auth { | ||
/** | ||
* Enable password protection | ||
* @default false | ||
*/ | ||
// Enable password protection | ||
// Default: false | ||
challenge?: boolean; | ||
/** | ||
* Users and their passwords | ||
* @example ```js | ||
{ "interstellarskidder": "superSecretPassword!!!" } | ||
``` | ||
*/ | ||
|
||
// Users and their passwords | ||
// Example: "username": "password", | ||
users?: Record<string, string>; | ||
} |