ember-cli / eslint-plugin-ember

An ESLint plugin that provides set of rules for Ember applications based on commonly known good practices.
MIT License
261 stars 202 forks source link

A failing test for no-deprecated-router-transition-methods (legacy class, decorators) #2073

Open CvX opened 8 months ago

CvX commented 8 months ago

This rule incorrectly fails on the following code, where a legacy .extend class uses decorators:

import Route from '@ember/routing/route';
import { action } from '@ember/object';

export default Route.extend({
  @action
  foo() {
    this.transitionTo('login');
  }
});
CvX commented 8 months ago

Added a test for the same issue in no-implicit-injections