This repository has been archived by the owner on Jul 15, 2023. It is now read-only.
promise-must-complete
false positive when passing resolve/reject out of scope
#329
Labels
Difficulty: Medium
People with non-trivial experience in TSLint should be able to send a pull request for this issue.
Microsoft Internal
Issues related to closed source Microsoft code.
Status: Accepting PRs
Type: Rule Feature
Adding a feature to an existing rule.
Take the following code snippet that lazy-loads an external script:
This would fail with
I would suggest providing a less-strict version of
promise-must-complete
rule, or an option, which bails out and allows the rule to pass whenresolve
and/orreject
are made available outside the scope of the promise's closure.The text was updated successfully, but these errors were encountered: