Index
Class for starting the API.
Example:
// Simply start the API by creating a new instance of the Index class.
const index = new Index();
// Or override the default configuration of the Index class.
const index = new Index({
start: true,
pretty: true,
verbose: false,
debug: false
});
Static Method Summary
| Static Public Methods | ||
| public static |
closeAPI() Function to stop the API from running. |
|
| Static Private Methods | ||
| private static |
Function to start the API. |
|
Constructor Summary
| Public Constructor | ||
| public |
constructor(config: Object) Create an index object. |
|
Static Public Methods
Static Private Methods
Public Constructors
public constructor(config: Object) source
Create an index object.
Params:
| Name | Type | Attribute | Description |
| config | Object | Configuration for the API. |
|
| config.start | Boolean |
|
Start the scraping process. |
| config.pretty | Boolean |
|
Pretty output with Winston logging. |
| config.verbose | Boolean |
|
Debug mode for no output. |
| config.debug | Boolean |
|
Debug mode for extra output. |