@aneuhold/be-ts-lib
v3.0.9
Published
A backend TypeScript library used for common functionality in personal backend projects.
Downloads
1,339
Readme
Personal Backend TypeScript Library
This is a library meant to contain any common code between backend TypeScript projects.
📦 Installation
To add to a repo, follow the instructions below for your environment:
For Node using NPM
Run pnpm add @aneuhold/be-ts-lib
For Node using JSR
The below instructions still allow for things like Renovate to work, and normal commands with pnpm such as pnpm up.
- Add the required JSR configuration to a
.npmrcfile if not there already:@jsr:registry=https://npm.jsr.io - Add the package with
pnpm add @jsr/aneuhold__be-ts-lib
For Deno
Run deno add jsr:@aneuhold/be-ts-lib
🟢 Usage
Pull in one of the services and use it like so:
import { ConfigService } from '@aneuhold/be-ts-lib';
// If using Node with JSR
// import { ConfigService } from '@jsr/aneuhold__be-ts-lib';
export default async function getConfig() {
await ConfigService.useConfig('local');
const config = ConfigService.config;
console.log(config);
}