Skip to content
This repository has been archived by the owner on Mar 25, 2021. It is now read-only.

import-destructuring-spacing not found #2486

Closed
lunanigra opened this issue Apr 3, 2017 · 4 comments
Closed

import-destructuring-spacing not found #2486

lunanigra opened this issue Apr 3, 2017 · 4 comments
Labels

Comments

@lunanigra
Copy link

Bug Report

  • 'import-destructuring-spacing' not working after update
  • tslint 5.0.0
  • Has been working before update. Other spacing configs also do not work as desired.
  • Might be duplicated; but no solution found...

tslint console output

Could not find implementations for the following rules specified in the configuration:
    import-destructuring-spacing
Try upgrading TSLint and/or ensuring that you have all necessary custom rules installed.
If TSLint was recently upgraded, you may have old rules configured which need to be cleaned up.

Actual behavior

Missing spaces; but no error... import {Injectable} from '@angular/core';

Expected behavior

Correct formatting... import { Injectable } from '@angular/core';
Or lint error if spaces are missing.

@ajafff
Copy link
Contributor

ajafff commented Apr 3, 2017

I guess you just upgraded codelyzer to v3.x?

mgechev/codelyzer#262 (comment)

@lunanigra
Copy link
Author

Hello, that might be the right direction... Yes, we upgraded to codelyzer 3.0.0-beta.4; the following error/warning seems to confirm your guess...

codelyzer@3.0.0-beta.4 requires a peer of tslint@^4.0.0 but none was installed.

@ajafff
Copy link
Contributor

ajafff commented Apr 4, 2017

There's not much we can do about this. The rule you are missing used to be provided by the 3rd party package codelyzer, which now dropped that rule. tslint currently has no equivalent.

Someone could contribute that functionality to the whitespace rule, though.

@adidahiya
Copy link
Contributor

the whitespace rule's "check-module" option ought to do this, according to its tests. it might be broken, see #2401

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

3 participants