How to fix "no-unused-variable is deprecated" in tslint


angular tslint Tutorials typescript

Hello! If you are from Ukraine, Belarus, Poland or India and looking for a job in Software Development, please reach me out by email.

This error you can face while running ng lint in Angular application:

no-unused-variable is deprecated. Since TypeScript 2.9. Please use the built-in compiler checks instead.

To fix this error you need to remove no-unused-variable flag from tslint.json. In your next run of ng lint an error will disappear:

no-unused-variable flag

This parameter is deprecated because Typescript has some functionality to avoid unused variables.

comments powered by Disqus