PureScript Alternatives logo

PureScript Alternatives

Explore the pros & cons of PureScript and its alternatives. Learn about popular competitors like Haskell, Elm, and TypeScript
88
86
+ 1
18

What is PureScript and what are its top alternatives?

PureScript is a strongly-typed functional programming language that compiles to JavaScript, allowing developers to write expressive and type-safe code that can be easily integrated into web applications. Key features include type inference, type classes, and a powerful type system that promotes correctness and safety. However, PureScript can have a steep learning curve for developers unfamiliar with functional programming paradigms, and its ecosystem may not be as robust as some other languages.

  1. Haskell: Haskell is a popular functional programming language known for its strong type system and elegant syntax. Key features include lazy evaluation, type classes, and purity. Pros: Robust type system, mature ecosystem. Cons: Steeper learning curve than PureScript.
  2. Elm: Elm is a functional programming language that focuses on simplicity and reliability for web development. Key features include a strong emphasis on usability and an architecture for creating robust web applications. Pros: Great for front-end web development, easy to learn. Cons: Limited interoperability with JavaScript.
  3. ClojureScript: ClojureScript is a functional programming language that compiles to JavaScript and shares the same syntax as Clojure. Key features include immutable data structures and a focus on simplicity. Pros: Interoperability with JavaScript, powerful macro system. Cons: Limited tooling compared to PureScript.
  4. ReasonML: ReasonML is a functional programming language that is a friendly cousin of JavaScript, and can interoperate with it seamlessly. Key features include a familiar syntax for JavaScript developers and a strong type system. Pros: Easy to learn for JavaScript developers, good interop with JavaScript. Cons: Limited ecosystem compared to PureScript.
  5. Fable: Fable is a functional programming language that brings F# to JavaScript development. Key features include type safety and a seamless integration with popular JavaScript libraries. Pros: Excellent tooling, strong type system. Cons: Limited resources compared to PureScript.
  6. Scala.js: Scala.js is a Scala compiler that targets JavaScript, bringing the power of the Scala language to web development. Key features include scalability and interoperability with Java libraries. Pros: Strong type system, mature ecosystem. Cons: Less suited for front-end web development than PureScript.
  7. TypeScript: TypeScript is a superset of JavaScript that adds static typing to the language. Key features include gradual typing and great tooling. Pros: Easy to learn for JavaScript developers, good tooling support. Cons: Less emphasis on functional programming than PureScript.
  8. Rust: Rust is a systems programming language known for its focus on safety and performance. Key features include memory safety and zero-cost abstractions. Pros: Memory safety guarantees, excellent performance. Cons: Steeper learning curve than PureScript.
  9. Kotlin for JavaScript: Kotlin is a modern programming language that can compile to JavaScript. Key features include null safety and interoperability with Java. Pros: Easy to learn for Java developers, great tooling support. Cons: Less emphasis on functional programming than PureScript.
  10. ElixirScript: ElixirScript is a compiler that brings the Elixir programming language to JavaScript environments. Key features include the actor model and fault tolerance. Pros: Functional programming features, fault tolerance. Cons: Limited resources compared to PureScript.

Top Alternatives to PureScript

  • Haskell
    Haskell

    It is a general purpose language that can be used in any domain and use case, it is ideally suited for proprietary business logic and data analysis, fast prototyping and enhancing existing software environments with correct code, performance and scalability. ...

  • Elm
    Elm

    Writing HTML apps is super easy with elm-lang/html. Not only does it render extremely fast, it also quietly guides you towards well-architected code. ...

  • TypeScript
    TypeScript

    TypeScript is a language for application-scale JavaScript development. It's a typed superset of JavaScript that compiles to plain JavaScript. ...

  • LiveScript
    LiveScript

    It has a straightforward mapping to JavaScript and allows you to write expressive code devoid of repetitive boilerplate. While LiveScript adds many features to assist in functional style programming, it also has many improvements for object oriented and imperative programming. ...

  • ClojureScript
    ClojureScript

    ClojureScript is a compiler for Clojure that targets JavaScript. It is designed to emit JavaScript code which is compatible with the advanced compilation mode of the Google Closure optimizing compiler. ...

  • ReasonML
    ReasonML

    It lets you write simple, fast and quality type safe code while leveraging both the JavaScript & OCaml ecosystems.It is powerful, safe type inference means you rarely have to annotate types, but everything gets checked for you. ...

  • React
    React

    Lots of people use React as the V in MVC. Since React makes no assumptions about the rest of your technology stack, it's easy to try it out on a small feature in an existing project. ...

  • JavaScript
    JavaScript

    JavaScript is most known as the scripting language for Web pages, but used in many non-browser environments as well such as node.js or Apache CouchDB. It is a prototype-based, multi-paradigm scripting language that is dynamic,and supports object-oriented, imperative, and functional programming styles. ...

PureScript alternatives & related posts

Haskell logo

Haskell

1.4K
527
An advanced purely-functional programming language
1.4K
527
PROS OF HASKELL
  • 90
    Purely-functional programming
  • 66
    Statically typed
  • 59
    Type-safe
  • 39
    Open source
  • 38
    Great community
  • 31
    Built-in concurrency
  • 30
    Built-in parallelism
  • 30
    Composable
  • 24
    Referentially transparent
  • 20
    Generics
  • 15
    Type inference
  • 15
    Intellectual satisfaction
  • 12
    If it compiles, it's correct
  • 8
    Flexible
  • 8
    Monads
  • 5
    Great type system
  • 4
    Proposition testing with QuickCheck
  • 4
    One of the most powerful languages *(see blub paradox)*
  • 4
    Purely-functional Programming
  • 3
    Highly expressive, type-safe, fast development time
  • 3
    Pattern matching and completeness checking
  • 3
    Great maintainability of the code
  • 3
    Fun
  • 3
    Reliable
  • 2
    Best in class thinking tool
  • 2
    Kind system
  • 2
    Better type-safe than sorry
  • 2
    Type classes
  • 1
    Predictable
  • 1
    Orthogonality
CONS OF HASKELL
  • 9
    Too much distraction in language extensions
  • 8
    Error messages can be very confusing
  • 5
    Libraries have poor documentation
  • 3
    No good ABI
  • 3
    No best practices
  • 2
    Poor packaging for apps written in it for Linux distros
  • 2
    Sometimes performance is unpredictable
  • 1
    Slow compilation
  • 1
    Monads are hard to understand

related Haskell posts

Shared insights
on
HaskellHaskellScalaScala

Why I am using Haskell in my free time?

I have 3 reasons for it. I am looking for:

Fun.

Improve functional programming skill.

Improve problem-solving skill.

Laziness and mathematical abstractions behind Haskell makes it a wonderful language.

It is Pure functional, it helps me to write better Scala code.

Highly expressive language gives elegant ways to solve coding puzzle.

See more
Elm logo

Elm

745
319
A type inferred, functional reactive language that compiles to HTML, CSS, and JavaScript
745
319
PROS OF ELM
  • 45
    Code stays clean
  • 44
    Great type system
  • 40
    No Runtime Exceptions
  • 33
    Fun
  • 28
    Easy to understand
  • 23
    Type safety
  • 22
    Correctness
  • 17
    JS fatigue
  • 12
    Ecosystem agrees on one Application Architecture
  • 12
    Declarative
  • 10
    Friendly compiler messages
  • 8
    Fast rendering
  • 7
    If it compiles, it runs
  • 7
    Welcoming community
  • 5
    Stable ecosystem
  • 4
    'Batteries included'
  • 2
    Package.elm-lang.org
CONS OF ELM
  • 3
    No typeclasses -> repitition (i.e. map has 130versions)
  • 2
    JS interop can not be async
  • 2
    JS interoperability a bit more involved
  • 1
    More code is required
  • 1
    No JSX/Template
  • 1
    Main developer enforces "the correct" style hard
  • 1
    No communication with users
  • 1
    Backwards compability breaks between releases

related Elm posts

Shared insights
on
ReactReactReduxReduxElmElm

React is awesome, but is just a view library, when we need to manage state, there is Redux.js. The ecosystem of redux is big, complex and hard to integrate. That's why we choose to create hydux. Hydux is simple, the main idea is from Elm, a pure functional vdom-based framework for front-end. We seperate the whole app with state, actions and views. Which means not only our views are a tree, but also our state and actions. Reuse state and actions are just like reuse react components, no need to consider dependences.

See more
TypeScript logo

TypeScript

94.9K
500
A superset of JavaScript that compiles to clean JavaScript output
94.9K
500
PROS OF TYPESCRIPT
  • 173
    More intuitive and type safe javascript
  • 105
    Type safe
  • 80
    JavaScript superset
  • 48
    The best AltJS ever
  • 27
    Best AltJS for BackEnd
  • 15
    Powerful type system, including generics & JS features
  • 11
    Compile time errors
  • 11
    Nice and seamless hybrid of static and dynamic typing
  • 10
    Aligned with ES development for compatibility
  • 7
    Angular
  • 7
    Structural, rather than nominal, subtyping
  • 5
    Starts and ends with JavaScript
  • 1
    Garbage collection
CONS OF TYPESCRIPT
  • 5
    Code may look heavy and confusing
  • 4
    Hype

related TypeScript posts

Yshay Yaacobi

Our first experience with .NET core was when we developed our OSS feature management platform - Tweek (https://github.com/soluto/tweek). We wanted to create a solution that is able to run anywhere (super important for OSS), has excellent performance characteristics and can fit in a multi-container architecture. We decided to implement our rule engine processor in F# , our main service was implemented in C# and other components were built using JavaScript / TypeScript and Go.

Visual Studio Code worked really well for us as well, it worked well with all our polyglot services and the .Net core integration had great cross-platform developer experience (to be fair, F# was a bit trickier) - actually, each of our team members used a different OS (Ubuntu, macos, windows). Our production deployment ran for a time on Docker Swarm until we've decided to adopt Kubernetes with almost seamless migration process.

After our positive experience of running .Net core workloads in containers and developing Tweek's .Net services on non-windows machines, C# had gained back some of its popularity (originally lost to Node.js), and other teams have been using it for developing microservices, k8s sidecars (like https://github.com/Soluto/airbag), cli tools, serverless functions and other projects...

See more
Adebayo Akinlaja
Engineering Manager at Andela · | 30 upvotes · 3.5M views

I picked up an idea to develop and it was no brainer I had to go with React for the frontend. I was faced with challenges when it came to what component framework to use. I had worked extensively with Material-UI but I needed something different that would offer me wider range of well customized components (I became pretty slow at styling). I brought in Evergreen after several sampling and reads online but again, after several prototype development against Evergreen—since I was using TypeScript and I had to import custom Type, it felt exhaustive. After I validated Evergreen with the designs of the idea I was developing, I also noticed I might have to do a lot of styling. I later stumbled on Material Kit, the one specifically made for React . It was promising with beautifully crafted components, most of which fits into the designs pages I had on ground.

A major problem of Material Kit for me is it isn't written in TypeScript and there isn't any plans to support its TypeScript version. I rolled up my sleeve and started converting their components to TypeScript and if you'll ask me, I am still on it.

In summary, I used the Create React App with TypeScript support and I am spending some time converting Material Kit to TypeScript before I start developing against it. All of these components are going to be hosted on Bit.

If you feel I am crazy or I have gotten something wrong, I'll be willing to listen to your opinion. Also, if you want to have a share of whatever TypeScript version of Material Kit I end up coming up with, let me know.

See more
LiveScript logo

LiveScript

99
0
A language which compiles to JavaScript
99
0
PROS OF LIVESCRIPT
    Be the first to leave a pro
    CONS OF LIVESCRIPT
      Be the first to leave a con

      related LiveScript posts

      ClojureScript logo

      ClojureScript

      312
      2
      A Clojure compiler targeting JavaScript
      312
      2
      PROS OF CLOJURESCRIPT
      • 2
        Functional and stable
      CONS OF CLOJURESCRIPT
        Be the first to leave a con

        related ClojureScript posts

        I adopted Clojure and ClojureScript because:

        • it's 1 language, multiple platforms.
        • Simple syntax.
        • Designed to avoid unwanted side effects and bugs.
        • Immutable data-structures.
        • Compact code, very expressive.
        • Source code is data.
        • It has super-flexible macro.
        • Has metadata.
        • Interoperability with JavaScript, Java and C#.
        See more
        ReasonML logo

        ReasonML

        75
        8
        A friendly programming language for JavaScript and OCaml
        75
        8
        PROS OF REASONML
        • 4
          Pattern Matching
        • 3
          Type System
        • 1
          React
        CONS OF REASONML
        • 1
          Bindings

        related ReasonML posts

        React logo

        React

        174.7K
        4.1K
        A JavaScript library for building user interfaces
        174.7K
        4.1K
        PROS OF REACT
        • 837
          Components
        • 673
          Virtual dom
        • 578
          Performance
        • 509
          Simplicity
        • 442
          Composable
        • 186
          Data flow
        • 166
          Declarative
        • 128
          Isn't an mvc framework
        • 120
          Reactive updates
        • 115
          Explicit app state
        • 50
          JSX
        • 29
          Learn once, write everywhere
        • 22
          Easy to Use
        • 21
          Uni-directional data flow
        • 17
          Works great with Flux Architecture
        • 11
          Great perfomance
        • 10
          Javascript
        • 9
          Built by Facebook
        • 8
          TypeScript support
        • 6
          Scalable
        • 6
          Server Side Rendering
        • 6
          Speed
        • 5
          Easy to start
        • 5
          Feels like the 90s
        • 5
          Hooks
        • 5
          Awesome
        • 5
          Cross-platform
        • 5
          Closer to standard JavaScript and HTML than others
        • 5
          Easy as Lego
        • 5
          Functional
        • 5
          Excellent Documentation
        • 5
          Props
        • 4
          Scales super well
        • 4
          Allows creating single page applications
        • 4
          Sdfsdfsdf
        • 4
          Start simple
        • 4
          Strong Community
        • 4
          Super easy
        • 4
          Server side views
        • 4
          Fancy third party tools
        • 3
          Rich ecosystem
        • 3
          Has arrow functions
        • 3
          Very gentle learning curve
        • 3
          Beautiful and Neat Component Management
        • 3
          Just the View of MVC
        • 3
          Simple, easy to reason about and makes you productive
        • 3
          Fast evolving
        • 3
          SSR
        • 3
          Great migration pathway for older systems
        • 3
          Simple
        • 3
          Has functional components
        • 3
          Every decision architecture wise makes sense
        • 2
          Sharable
        • 2
          Permissively-licensed
        • 2
          HTML-like
        • 2
          Image upload
        • 2
          Recharts
        • 2
          Fragments
        • 2
          Split your UI into components with one true state
        • 1
          React hooks
        • 1
          Datatables
        CONS OF REACT
        • 41
          Requires discipline to keep architecture organized
        • 30
          No predefined way to structure your app
        • 29
          Need to be familiar with lots of third party packages
        • 13
          JSX
        • 10
          Not enterprise friendly
        • 6
          One-way binding only
        • 3
          State consistency with backend neglected
        • 3
          Bad Documentation
        • 2
          Error boundary is needed
        • 2
          Paradigms change too fast

        related React posts

        Johnny Bell

        I was building a personal project that I needed to store items in a real time database. I am more comfortable with my Frontend skills than my backend so I didn't want to spend time building out anything in Ruby or Go.

        I stumbled on Firebase by #Google, and it was really all I needed. It had realtime data, an area for storing file uploads and best of all for the amount of data I needed it was free!

        I built out my application using tools I was familiar with, React for the framework, Redux.js to manage my state across components, and styled-components for the styling.

        Now as this was a project I was just working on in my free time for fun I didn't really want to pay for hosting. I did some research and I found Netlify. I had actually seen them at #ReactRally the year before and deployed a Gatsby site to Netlify already.

        Netlify was very easy to setup and link to my GitHub account you select a repo and pretty much with very little configuration you have a live site that will deploy every time you push to master.

        With the selection of these tools I was able to build out my application, connect it to a realtime database, and deploy to a live environment all with $0 spent.

        If you're looking to build out a small app I suggest giving these tools a go as you can get your idea out into the real world for absolutely no cost.

        See more
        Collins Ogbuzuru
        Front-end dev at Evolve credit · | 44 upvotes · 327.2K views

        Your tech stack is solid for building a real-time messaging project.

        React and React Native are excellent choices for the frontend, especially if you want to have both web and mobile versions of your application share code.

        ExpressJS is an unopinionated framework that affords you the flexibility to use it's features at your term, which is a good start. However, I would recommend you explore Sails.js as well. Sails.js is built on top of Express.js and it provides additional features out of the box, especially the Websocket integration that your project requires.

        Don't forget to set up Graphql codegen, this would improve your dev experience (Add Typescript, if you can too).

        I don't know much about databases but you might want to consider using NO-SQL. I used Firebase real-time db and aws dynamo db on a few of my personal projects and I love they're easy to work with and offer more flexibility for a chat application.

        See more
        JavaScript logo

        JavaScript

        364.1K
        8.1K
        Lightweight, interpreted, object-oriented language with first-class functions
        364.1K
        8.1K
        PROS OF JAVASCRIPT
        • 1.7K
          Can be used on frontend/backend
        • 1.5K
          It's everywhere
        • 1.2K
          Lots of great frameworks
        • 898
          Fast
        • 746
          Light weight
        • 425
          Flexible
        • 392
          You can't get a device today that doesn't run js
        • 286
          Non-blocking i/o
        • 237
          Ubiquitousness
        • 191
          Expressive
        • 55
          Extended functionality to web pages
        • 49
          Relatively easy language
        • 46
          Executed on the client side
        • 30
          Relatively fast to the end user
        • 25
          Pure Javascript
        • 21
          Functional programming
        • 15
          Async
        • 13
          Full-stack
        • 12
          Future Language of The Web
        • 12
          Its everywhere
        • 12
          Setup is easy
        • 11
          Because I love functions
        • 11
          JavaScript is the New PHP
        • 10
          Like it or not, JS is part of the web standard
        • 9
          Expansive community
        • 9
          Everyone use it
        • 9
          Can be used in backend, frontend and DB
        • 9
          Easy
        • 8
          For the good parts
        • 8
          Powerful
        • 8
          Can be used both as frontend and backend as well
        • 8
          No need to use PHP
        • 8
          Easy to hire developers
        • 8
          Most Popular Language in the World
        • 7
          Its fun and fast
        • 7
          Hard not to use
        • 7
          Versitile
        • 7
          Nice
        • 7
          It's fun
        • 7
          Popularized Class-Less Architecture & Lambdas
        • 7
          Agile, packages simple to use
        • 7
          Supports lambdas and closures
        • 7
          Love-hate relationship
        • 7
          Photoshop has 3 JS runtimes built in
        • 7
          Evolution of C
        • 6
          Can be used on frontend/backend/Mobile/create PRO Ui
        • 6
          Easy to make something
        • 6
          It let's me use Babel & Typescript
        • 6
          1.6K Can be used on frontend/backend
        • 6
          Client side JS uses the visitors CPU to save Server Res
        • 5
          Scope manipulation
        • 5
          Clojurescript
        • 5
          Everywhere
        • 5
          What to add
        • 5
          Promise relationship
        • 5
          Stockholm Syndrome
        • 5
          Function expressions are useful for callbacks
        • 5
          Client processing
        • 4
          Only Programming language on browser
        • 4
          Because it is so simple and lightweight
        • 1
          Test2
        • 1
          Hard to learn
        • 1
          Subskill #4
        • 1
          Not the best
        • 1
          Easy to learn and test
        • 1
          Easy to understand
        • 1
          Easy to learn
        • 1
          Test
        • 0
          Hard 彤
        CONS OF JAVASCRIPT
        • 22
          A constant moving target, too much churn
        • 20
          Horribly inconsistent
        • 15
          Javascript is the New PHP
        • 9
          No ability to monitor memory utilitization
        • 8
          Shows Zero output in case of ANY error
        • 7
          Thinks strange results are better than errors
        • 6
          Can be ugly
        • 3
          No GitHub
        • 2
          Slow
        • 0
          HORRIBLE DOCUMENTS, faulty code, repo has bugs

        related JavaScript posts

        Zach Holman

        Oof. I have truly hated JavaScript for a long time. Like, for over twenty years now. Like, since the Clinton administration. It's always been a nightmare to deal with all of the aspects of that silly language.

        But wowza, things have changed. Tooling is just way, way better. I'm primarily web-oriented, and using React and Apollo together the past few years really opened my eyes to building rich apps. And I deeply apologize for using the phrase rich apps; I don't think I've ever said such Enterprisey words before.

        But yeah, things are different now. I still love Rails, and still use it for a lot of apps I build. But it's that silly rich apps phrase that's the problem. Users have way more comprehensive expectations than they did even five years ago, and the JS community does a good job at building tools and tech that tackle the problems of making heavy, complicated UI and frontend work.

        Obviously there's a lot of things happening here, so just saying "JavaScript isn't terrible" might encompass a huge amount of libraries and frameworks. But if you're like me, yeah, give things another shot- I'm somehow not hating on JavaScript anymore and... gulp... I kinda love it.

        See more
        Conor Myhrvold
        Tech Brand Mgr, Office of CTO at Uber · | 44 upvotes · 13.1M views

        How Uber developed the open source, end-to-end distributed tracing Jaeger , now a CNCF project:

        Distributed tracing is quickly becoming a must-have component in the tools that organizations use to monitor their complex, microservice-based architectures. At Uber, our open source distributed tracing system Jaeger saw large-scale internal adoption throughout 2016, integrated into hundreds of microservices and now recording thousands of traces every second.

        Here is the story of how we got here, from investigating off-the-shelf solutions like Zipkin, to why we switched from pull to push architecture, and how distributed tracing will continue to evolve:

        https://eng.uber.com/distributed-tracing/

        (GitHub Pages : https://www.jaegertracing.io/, GitHub: https://github.com/jaegertracing/jaeger)

        Bindings/Operator: Python Java Node.js Go C++ Kubernetes JavaScript OpenShift C# Apache Spark

        See more