Better HN
topnewbestaskshowjobs
Log inSign up

purescript

96 karma · joined Nov 12, 2014 (12y ago) · 59 submissions

purescript.org
Submissions

1.

Hasura Announces $100M Series C funding(hasura.io ↗)

2 points · by purescript · 4y ago · discuss

2.

Building a GraphQL-to-SQL compiler on Postgres, MSSQL and MySQL(hasura.io ↗)

5 points · by purescript · 5y ago · discuss

3.

Hasura 2.0 Engineering Overview(hasura.io ↗)

6 points · by purescript · 5y ago · discuss

4.

PureScript 0.14 Released(discourse.purescript.org ↗)

4 points · by purescript · 5y ago · discuss

comment 6y ago · link · parent

I'm curious why this isn't a backend for the existing PureScript compiler, since the front-end seems to be copy-paste identical?

6.

Halogen 5, a type-safe library for building user interfaces in PureScript(github.com ↗)

2 points · by purescript · 6y ago · discuss

7.

Bow Arch 0.1.0(47deg.com ↗)

1 points · by purescript · 6y ago · discuss

comment 8y ago · link · parent

PureScript has a lenient FFI so you can choose to use 99% pure functions if you like (at your own risk).

comment 9y ago · link · parent

Yes it does.

comment 9y ago · link · parent

This seems like it could be useful, but I don't seem to be able to create a discussion which is visible to everyone, yet only editable my members of my team, which is my main use case (for discussing project direction and such). "Public" seems to mean "visible to everyone in the organization".

comment 9y ago · link · parent

You might find our recent blog post interesting:

https://medium.com/fuzzy-sharp/migrating-to-postgres-2dc1519...

TL;DR: persistent + esqueleto + servant

comment 9y ago · link · parent

Category theory matters to programming because, among other things, it teaches us how to abstract over programming languages. What better definition of abstract programs than "things with types which compose"?

Now consider categories with various types of constructions (products, limits, exponentials, etc.) and you'll notice they correspond to requiring certain features in your language.

comment 9y ago · link · parent

https://trends.google.com/trends/explore?q=purescript,scalaj...

comment 9y ago · link · parent

I work on the PureScript (http://purescript.org) compiler, tools, libraries and book in my spare time (along with many other unpaid contributors), because it's the programming language I wished had existed when I started creating it. It's still the closest thing to a perfect environment for web development, at least as far as I'm concerned :)

comment 9y ago · link · parent

Just model this as taking an old, immutable web to a new one.

    impact :: Web -> Web
Persistent data structures will let us reuse the best parts of the old web efficiently.

comment 9y ago · link · parent

> Aside from apps at work

Now I'm curious :)

comment 9y ago · link · parent

Here is foldl implemented using foldr in PureScript, along with an example of using laziness to gain modularity:

http://try.purescript.org/?gist=63d81adf9f5257ffa4f576df2658...

comment 9y ago · link · parent

We recently added a way to dump out the compiler's intermediate representation as JSON, so it's actually very straightforward to create new backends by transforming that output [1].

The representation is fairly compact, so the requirements for a PureScript compiler backend are fairly minimal. You just have to translate all of the features of the IR:

- Functions with lexical scoping - Support for the primitive types defined by PureScript (we need to define some of these types more concretely in a specification) - A way to encode records. This could be something like JavaScript's objects, or just a map data structure.

The JS backend actually does more optimizations before code generation, but it starts from the same intermediate representation.

[1] https://github.com/paf31/24-days-of-purescript-2016/blob/mas...

comment 9y ago · link · parent

Halogen is not the only option for building web applications with PureScript. There are simpler options like Pux and Thermite, which are possibly much easier to teach. Halogen is optimized for a different use case.

comment 9y ago · link · parent

You don't need to constrain yourself. AltJS allows users to mix and match different languages for different problems. Use a pure functional language where it makes sense for you, and don't where it doesn't.

comment 9y ago · link · parent

This is from 2014. Here is the 2016 version: https://github.com/paf31/24-days-of-purescript-2016

22.

Simulating a galaxy in Purescript(sloosch.de ↗)

2 points · by purescript · 10y ago · discuss

23.

Dot Waves: A PureScript Short Story(bitantics.com ↗)

2 points · by purescript · 10y ago · discuss

24.

Announcing PureScript 0.8(blog.functorial.com ↗)

4 points · by purescript · 10y ago · discuss

comment 10y ago · link · parent

> to become even more hardcore on algebra and categoric language

In some of the standard libraries, yes, that's true. However, it's possible to use PureScript without the standard libraries, and use alternatives such as Preface (a teaching library) or Neon (an alternative to Prelude)

https://github.com/paf31/purescript-preface

http://pursuit.purescript.org/packages/purescript-neon/0.1.1

comment 10y ago · link · parent

The situation has improved since cabal install was required.

npm install -g pulp purescript

should be enough now.

12