question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

use-life-cycle-interface support for inheritance

See original GitHub issue

If I have the following, would it be possible for the rule use-life-cycle-interface to not throw a lint error?

class Parent implements OnInit {
    public ngOnInit() {
    }
}

class Child extends Parent {
    public ngOnInit() {
        super.ngOnInit();
    }
}

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Reactions:5
  • Comments:10 (2 by maintainers)

github_iconTop GitHub Comments

12reactions
paulshelestovichcommented, Mar 13, 2018

Still happening, same error with inheritance

8reactions
antchcommented, Jun 4, 2019

This issue should be re-opened.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Lifecycle - Android Developers
An implementation of Lifecycle that can handle multiple observers. Defines an object that has an Android Lifecycle. Fragment and ...
Read more >
How do I resolve error message: "Inheritance from an interface ...
It seems like you are either directly or indirectly (through some other library) depending on Lifecycle 2.5.0-alpha01 . As per this issue:.
Read more >
A misconception about Angular life-cycle methods
Explaining how life-cycle methods gets called when a component class extends another. Inheritance is one of the best ways to reuse code.
Read more >
AndroidX Lifecycle on steroids (aka multiple inheritance)
Lifecycle -aware components perform actions in response to a change in the lifecycle status of another component, such as activities and ...
Read more >
Lifecycle hooks - Angular
For example, the OnInit interface has a hook method named ngOnInit() . If you implement this method in your component or directive class,...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found