Registry / testing / ts-tslint-formatter

ts-tslint-formatter

JSON →
library0.1.0jsnpmunverified

A collection of custom formatters for TSLint errors, providing output formatting options beyond TSLint's built-in formatters. Version 0.1.0 is the latest stable release. The package is designed for use with TSLint 5.x and provides TypeScript type definitions. It is a niche utility for developers who need custom error output formatting for TSLint, compatible with Node.js and browser environments. The package is currently in stable state but has not seen recent updates.

npm install ts-tslint-formatter
INSTALL
IMPORT
SIG · TS-TSLINT-FORMATTE
T
ts-tslint-formatter
testingjavascriptv0.1.0
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

tslint-formatter
// Import formatter via TSLint configuration: 'ts-tslint-formatter'
Direct import: import formatter from 'ts-tslint-formatter'
Formatters are used via TSLint configuration file, not imported directly in code.
Formatter
// See package for available formatter names: e.g., 'stylish'
import { Formatter } from 'ts-tslint-formatter'
No named export - formatters are registered by name in TSLint config.
default
// No default export
import formatter from 'ts-tslint-formatter'
Package does not have a default export; it provides formatter files accessible via TSLint.

Shows how to install and configure the custom formatter with TSLint.

// Install package npm install ts-tslint-formatter --save-dev // In tslint.json, add formatter directory: { "formattersDirectory": "node_modules/ts-tslint-formatter/dist/formatters/", "formatter": "customFormatterName" } // Then run TSLint as usual
Debug
Known issues
gotchaFormatters must be referenced by name in TSLint configuration, and the package must be installed as a dev dependency.
fix
Add 'formattersDirectory' and 'formatter' fields to your tslint.json.
affects: >=0.1.0
deprecatedTSLint is deprecated in favor of ESLint. This package is unlikely to receive updates.
fix
Migrate to ESLint with appropriate plugins.
affects: >=0.1.0
Errors
Common errors & fixes
Cannot find formatter 'customFormatterName'
TSLint cannot locate the formatter in the specified directory.
fix
Check that formattersDirectory points to the correct path (e.g., 'node_modules/ts-tslint-formatter/dist/formatters/').
TypeError: formatter is not a function
Attempting to import the package directly instead of using it via TSLint config.
fix
Configure the formatter in tslint.json; do not import in source code.
Upgrade
Version history
0.1.0latest on npm
Audit
Dependencies
tslintrequiredPeer dependency required for the formatters to work with TSLint errors.
Agent activity
6 hits · last 30 days
node
6
Resources
ts-tslint-formatter — npm install ts-tslint-formatter · libregistry