@putout/plugin-remove-unused-types

putout plugin adds ability to find and remove unused types

Usage no npm install needed!

<script type="module">
  import putoutPluginRemoveUnusedTypes from 'https://cdn.skypack.dev/@putout/plugin-remove-unused-types';
</script>

README

@putout/plugin-remove-unused-types NPM version

🐊Putout plugin adds ability to find and remove unused types. Moved to @putout/plugin-typescript

Install

npm i @putout/plugin-remove-unused-types -D

Rule

{
    "rules": {
        "remove-unused-types": "on"
    }
}

❌ Incorrect code example

type n = number;
type s = string;

const x: n = 5;

✅ Correct code Example

type n = number;

const x: n = 5;

License

MIT