Giter Club home page Giter Club logo

Comments (2)

einargs avatar einargs commented on September 15, 2024

We might also be able to use Ormolu: https://www.tweag.io/posts/2019-10-11-ormolu-first-release.html

It makes some strange formatting choices though (but does have some justification for them), and is in beta, so I wouldn't consider it a top contender.

from nifti-hs.

sremedios avatar sremedios commented on September 15, 2024

What do you think of this comment? https://www.reddit.com/r/haskell/comments/8x0x77/brittany_vs_hindent_vs_stylishhaskell/e2076ig/

I watched several tutorials online with a guy who just used hlint and hindent. I like sticking to a standard rather than going for aesthetics (though hopefully the standard is also aesthetic).

For example, if I were doing a C style guide I'd prefer to always have this:

if (SOME_PREDICATE) {
    // something
}

over

if (SOME_PREDICATE) // something

even if the latter is more compact because consistency is readable.

For that reason I like both hindent according to the above reddit comment, but also Ormolu, which both considers standardization as well as questions the previous rationale, for example, with leading commas in multiline lists. I also like that GHC supports trailing commas now, did not know that.

from nifti-hs.

Related Issues (1)

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.