When comparing GHCJS vs Mint, the Slant community recommends GHCJS for most people. In the question“What are the best solutions to "The JavaScript Problem"?” GHCJS is ranked 8th while Mint is ranked 22nd. The most important reason people chose GHCJS is:
With a Haskell backend, GHCJS enables code sharing. In combination with the power of Haskell as a language, this enables an extremely tight integration of the client side with the server side, where all the communications take place in a type-safe manner and even transparently if desired.
Specs
Ranked in these QuestionsQuestion Ranking
Pros
Pro Full Stack Code Sharing
With a Haskell backend, GHCJS enables code sharing. In combination with the power of Haskell as a language, this enables an extremely tight integration of the client side with the server side, where all the communications take place in a type-safe manner and even transparently if desired.
Pro All of Haskell, with the same tools you're used to
No need to learn new syntax or semantics, and no need to install and learn a bunch of new tools - it's just GHC.
Pro Mature language and community
Pro Terse
Haskell is a very terse language, particularly due to its type inference. This means there's nothing to distract from the intent of the code, making it very readable. This is in sharp contrast to languages like Java, where skimming code requires learning which details can be ignored. Haskell's terseness also lends itself to very clear inline examples in textbooks, and makes it a pleasure to read through code even on a cellphone screen.
Pro Quick Feedback
It's often said that, in Haskell, if it compiles, it works. This short feedback loop can speed up learning process, by making it clear exactly when and where mistakes are made.
Pro Writen in Crystal (Language)
Crystal is one of the best and elegant languages.
Pro Constructs for synchronous and asynchronous computations
Pro Easy to learn and write
Everything is an expression.
Pro HTML and CSS integration
HTML can be written with minimal differences.
Scoped .CSS can be written for elements in components.
Pro Good error support
200+ unique error messages to help you on the way.
Pro Everything is typed
Everything is typed using a simple type system
Pro Dead code elimination
Only used parts of the code compiles into the final bundle.
Pro Built-in formatter
Mint has a built-in formatter to format your code, it can run standalone or with the development server.
Pro Batteries included
Mint contains everything you need to build the frontend of web applications from styling to data storage through HTTP requests to testing.
Pro Integrated testing
Testing is part of the language and there is a test runner built in which runs tests in the browser.
Cons
Con Large runtime
GHCJS supports the entire Haskell runtime, the Javascript it outputs tends to be quite large. This is in contrast to options such as Fay, which save some overhead by not supporting some features such as multi-threading.