Skip to main content
Home
This package has been archived, and as such it is read-only.

Built and signed on GitHub Actions

The Config utility reads and retrieves values from a config.json file in the current directory. It loads the JSON file, parses it, and returns the value for a given key.

This package works with Node.js, Deno, Bun
This package works with Node.js
This package works with Deno
This package works with Bun
JSR Score
100%
Published
a year ago (0.1.4)

This module provides a utility function Config for reading and retrieving configuration values from a config.json file located in the current working directory. The function reads the JSON file, parses it, and returns the value corresponding to a specified key.

Note

Make sure you have a config.json file in your current working directory. You can create one with the required configuration values.

Usage

import { Config } from '@blitz-bots/config';

const apiKey = Config('API_KEY');
console.log(apiKey); 
Built and signed on
GitHub Actions

New Ticket: Report package

Please provide a reason for reporting this package. We will review your report and take appropriate action.

Please review the JSR usage policy before submitting a report.

Add Package

deno add jsr:@blitz-bots/config

Import symbol

import * as config from "@blitz-bots/config";
or

Import directly with a jsr specifier

import * as config from "jsr:@blitz-bots/config";

Add Package

pnpm i jsr:@blitz-bots/config
or (using pnpm 10.8 or older)
pnpm dlx jsr add @blitz-bots/config

Import symbol

import * as config from "@blitz-bots/config";

Add Package

yarn add jsr:@blitz-bots/config
or (using Yarn 4.8 or older)
yarn dlx jsr add @blitz-bots/config

Import symbol

import * as config from "@blitz-bots/config";

Add Package

vlt install jsr:@blitz-bots/config

Import symbol

import * as config from "@blitz-bots/config";

Add Package

npx jsr add @blitz-bots/config

Import symbol

import * as config from "@blitz-bots/config";

Add Package

bunx jsr add @blitz-bots/config

Import symbol

import * as config from "@blitz-bots/config";