Skip to content

Support for untilDestroyed alias in rxjs-angular/prefer-takeuntil #13

@Kulikov17

Description

@Kulikov17

Hello! I use this rule:

"rxjs-angular/prefer-takeuntil": [
    "error",
    {
        "alias": ["untilDestroyed"],
        "checkComplete": true,
        "checkDecorators": ["Component"],
        "checkDestroy": true
    }
]

I also use untilDestroyed() from the library @ngneat/until-destroy.

Errors occur:

14:14  error  `ngOnDestroy` is not implemented                                 rxjs-angular/prefer-takeuntil
29:14  error  Forbids calling `subscribe` without an accompanying `takeUntil`  rxjs-angular/prefer-takeuntil

I think this is due to the incorrect work of "alias". Once this issue was already raised, but it was only fixed in rxjs-no-unsafe-takeuntil.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions