Skip to content

Lpmvb/eslint-typegen

 
 

Repository files navigation

eslint-typegen

npm version npm downloads bundle JSDocs License

Generate types from ESLint rules schema

Usage

npm i eslint-typegen
import fs from 'node:fs/promises'
import { generateTypes } from 'eslint-typegen'
import pluginTs from '@typescript-eslint/eslint-plugin'
import pluginN from 'eslint-plugin-n'

const dts = await pluginsToRulesOptions({
  '@typescript-eslint': pluginTs,
  'n': pluginN,
})

await fs.writeFile('eslint-rules.d.ts', dts)

Sponsors

Credits

The initial idea comes from @Shinigami92 via this PR, thanks to him!

License

MIT License © 2023-PRESENT Anthony Fu

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • TypeScript 94.2%
  • JavaScript 5.8%