@4lch4/api-starter
Advanced tools
Comparing version 0.0.5 to 0.2.0
import { IAppConfig } from './interfaces/index.js'; | ||
import { Server } from './lib/index.js'; | ||
/** | ||
* Creates a basic Koa server instance, adds some middleware, adds some default | ||
* routes (health checks), and then returns the server instance. | ||
* | ||
* @param config The configuration for the server. | ||
* @returns An instance of the {@link Server} class. | ||
*/ | ||
export declare function getServerStarter(config: IAppConfig): Promise<Server>; | ||
/** This object contains all interfaces exported by the package. */ | ||
export * as Interfaces from './interfaces/index.js'; | ||
/** This object contains all class bases exported by the package. */ | ||
export * as Bases from './lib/bases/index.js'; | ||
/** This object contains all the constants exported by the package. */ | ||
export * as Constants from './lib/constants/index.js'; | ||
/** This object contains all the utility classes exported by the package. */ | ||
export * as Utils from './lib/utils/index.js'; | ||
/** This object contains all the API routes exported by the package. */ | ||
export * as Routes from './routes/index.js'; | ||
//# sourceMappingURL=index.d.ts.map |
import { DEFAULT_APP_CONFIG, Server } from './lib/index.js'; | ||
import { getRoutes } from './routes/index.js'; | ||
//#region Exports | ||
/** | ||
* Creates a basic Koa server instance, adds some middleware, adds some default | ||
* routes (health checks), and then returns the server instance. | ||
* | ||
* @param config The configuration for the server. | ||
* @returns An instance of the {@link Server} class. | ||
*/ | ||
export async function getServerStarter(config) { | ||
@@ -19,2 +27,13 @@ try { | ||
} | ||
/** This object contains all interfaces exported by the package. */ | ||
export * as Interfaces from './interfaces/index.js'; | ||
/** This object contains all class bases exported by the package. */ | ||
export * as Bases from './lib/bases/index.js'; | ||
/** This object contains all the constants exported by the package. */ | ||
export * as Constants from './lib/constants/index.js'; | ||
/** This object contains all the utility classes exported by the package. */ | ||
export * as Utils from './lib/utils/index.js'; | ||
/** This object contains all the API routes exported by the package. */ | ||
export * as Routes from './routes/index.js'; | ||
//#endregion Exports | ||
//# sourceMappingURL=index.js.map |
{ | ||
"name": "@4lch4/api-starter", | ||
"displayName": "API Starter", | ||
"version": "0.0.5", | ||
"version": "0.2.0", | ||
"description": "An NPM package to use for starting a new API within my infrastructure.", | ||
@@ -12,16 +12,11 @@ "main": "./dist/index.js", | ||
"homepage": "https://git.4lch4.io/4lch4/API-Starter", | ||
"scripts": { | ||
"start": "node dist/index.js", | ||
"dplr:start": "doppler run -p $CRONICLE_PROJECT --config $CRONICLE_CONFIG --command='DEBUG=$DEBUG node ./dist/index.js'", | ||
"build": "tsc", | ||
"pretty": "prettier --write .", | ||
"pretty:git": "prettier --write . && if [[ $(git status -s) ]]; then git commit -a -m 'chore(pretty): project prettied'; fi", | ||
"lint": "prettier -c .", | ||
"test": "echo 'There are currently no tests available.'", | ||
"scan": "snyk monitor && snyk code test", | ||
"preversion": "npm run pretty:git", | ||
"postversion": "if [[ $(git status -s) ]]; then git commit -a -m 'chore(npm): version bump'; fi" | ||
}, | ||
"files": [ | ||
"dist" | ||
"dist", | ||
".prettierrc", | ||
".prettierignore", | ||
"Dockerfile", | ||
"pnpm-lock.yaml", | ||
"Taskfile.yml", | ||
"tsconfig.json", | ||
"package.json" | ||
], | ||
@@ -69,3 +64,15 @@ "engines": { | ||
"typescript": "^4.9.4" | ||
}, | ||
"scripts": { | ||
"start": "node dist/index.js", | ||
"dplr:start": "doppler run -p $CRONICLE_PROJECT --config $CRONICLE_CONFIG --command='DEBUG=$DEBUG node ./dist/index.js'", | ||
"build": "tsc", | ||
"pretty": "prettier --write .", | ||
"pretty:git": "prettier --write . && if [[ $(git status -s) ]]; then git commit -a -m 'chore(pretty): project prettied'; fi", | ||
"lint": "prettier -c .", | ||
"test": "echo 'There are currently no tests available.'", | ||
"scan": "snyk monitor && snyk code test", | ||
"preversion": "npm run pretty:git", | ||
"postversion": "if [[ $(git status -s) ]]; then git commit -a -m 'chore(npm): version bump'; fi" | ||
} | ||
} | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
116882
56
343