UNPKG

@types/conventional-changelog-preset-loader

Version:
70 lines (57 loc) 2.98 kB
# Installation > `npm install --save @types/conventional-changelog-preset-loader` # Summary This package contains type definitions for conventional-changelog-preset-loader (https://github.com/conventional-changelog/conventional-changelog/tree/master/packages/conventional-changelog-preset-loader#readme). # Details Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/conventional-changelog-preset-loader. ## [index.d.ts](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/conventional-changelog-preset-loader/index.d.ts) ````ts import { Options as CoreOptions } from "conventional-changelog-core"; import { Context as WriterContext } from "conventional-changelog-writer"; import { Commit } from "conventional-commits-parser"; /** * The string that is passed to the preset loader is manipulated by prepending * `conventional-changelog` to the name. * * For example: * * * `angular` => `conventional-changelog-angular` * * `angular/preset/path` => `conventional-changelog-angular/preset/path` * * `@scope/angular` => `@scope/conventional-changelog-angular` * * `@scope/angular/preset/path` => `@scope/conventional-changelog-angular/preset/path` * * Will return whatever is exported by the preset package. That may be a * configuration object, a function, or a promise. * * @param path */ declare function conventionalChangelogPresetLoader(path: string | Config): CoreOptions.Config; declare namespace conventionalChangelogPresetLoader { function presetLoader(requireMethod: presetLoader.RequireMethod): typeof conventionalChangelogPresetLoader; namespace presetLoader { type RequireMethod = (id: string) => any; } type Builder = (config: CoreOptions.Config.Object & Config) => CoreOptions.Config; interface Config { /** * The string that is passed to the preset loader is manipulated by prepending * `conventional-changelog` to the name. * * For example: * * * `angular` => `conventional-changelog-angular` * * `angular/preset/path` => `conventional-changelog-angular/preset/path` * * `@scope/angular` => `@scope/conventional-changelog-angular` * * `@scope/angular/preset/path` => `@scope/conventional-changelog-angular/preset/path` */ name: string; } } type Config = conventionalChangelogPresetLoader.Config; export = conventionalChangelogPresetLoader; ```` ### Additional Details * Last updated: Mon, 25 Nov 2024 22:35:05 GMT * Dependencies: [@types/conventional-changelog-core](https://npmjs.com/package/@types/conventional-changelog-core), [@types/conventional-changelog-writer](https://npmjs.com/package/@types/conventional-changelog-writer), [@types/conventional-commits-parser](https://npmjs.com/package/@types/conventional-commits-parser) # Credits These definitions were written by [Jason Kwok](https://github.com/JasonHK).