0.1.0 • Published 4 months ago

@tylerbu/lilconfig-loader-ts v0.1.0

Weekly downloads
-
License
MIT
Repository
github
Last release
4 months ago

@tylerbu/lilconfig-loader-ts

A TypeScript loader for lilconfig, enabling you to load TypeScript configuration files in lilconfig.

Installation

npm install @tylerbu/lilconfig-loader-ts

Usage

import { lilconfig } from "lilconfig";
import { TypeScriptLoader } from "@tylerbu/lilconfig-loader-ts";

const moduleName = "myModuleName";
const explorer = lilconfig(moduleName, {
  searchPlaces: [
    "package.json",
    `.${moduleName}rc`,
    `.${moduleName}rc.json`,
    `.${moduleName}rc.ts`,
    `.${moduleName}rc.js`,
    `${moduleName}.config.ts`,
    `${moduleName}.config.js`,
  ],
  loaders: {
    ".ts": TypeScriptLoader,
  },
});
0.1.0

4 months ago