Giter VIP home page Giter VIP logo

Comments (9)

xjamundx avatar xjamundx commented on May 18, 2024

@feross Yeah catch is maybe slightly better, because it will also catch programmer errors in the doSomething code, but it's certainly better than nothing. Maybe I can add an exception or something. Thanks for the idea. Will mull it over a bit.

from eslint-plugin-promise.

feross avatar feross commented on May 18, 2024

Yep, I understand. I just couldn't enable this rule without causing tons of standard users' code to fail. If there's a way to just check that there's any catch handler in then() or catch(), that would be a good candidate to enable for all standard users.

from eslint-plugin-promise.

xjamundx avatar xjamundx commented on May 18, 2024

I'll add a configurable exception "always-catch": [2, { allowThen: true }]. Think that might work?

from eslint-plugin-promise.

feross avatar feross commented on May 18, 2024

@xjamundx Yep, that'd work.

from eslint-plugin-promise.

xjamundx avatar xjamundx commented on May 18, 2024

K give me a week if it don't forget !

On Tue, Feb 23, 2016 at 1:07 PM, Feross Aboukhadijeh <
[email protected]> wrote:

@xjamundx https://github.com/xjamundx Yep, that'd work.


Reply to this email directly or view it on GitHub
#4 (comment)
.

from eslint-plugin-promise.

xjamundx avatar xjamundx commented on May 18, 2024

A lot of people are also saying if the promise is returned it doesn't need
to be caught. I may also add this exception

On Tue, Feb 23, 2016 at 1:07 PM, Jamund Ferguson [email protected] wrote:

K give me a week if it don't forget !

On Tue, Feb 23, 2016 at 1:07 PM, Feross Aboukhadijeh <
[email protected]> wrote:

@xjamundx https://github.com/xjamundx Yep, that'd work.


Reply to this email directly or view it on GitHub
#4 (comment)
.

from eslint-plugin-promise.

xjamundx avatar xjamundx commented on May 18, 2024

Started on this

from eslint-plugin-promise.

xjamundx avatar xjamundx commented on May 18, 2024

Closed by 41f1c02

from eslint-plugin-promise.

feross avatar feross commented on May 18, 2024

Nice, will try to release this in standard v7!

from eslint-plugin-promise.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.