r/purescript • • Jul 17 '25

Is it worth learning PureScript? So far the experience was less than ideal.

I am not a Java or SQL programmer, but I was able to quickly get up and going. The error messages made sense. The documentation had plenty of excellent examples.

Here you get confusing type errors. Some examples on the web appear to be broken on purpose, so they are useless. Type signatures are not examples. There is very little traffic on the discourse. Copilot gives nonsense answers and even contradicts itself.

So, I am asking, is there a light at the end of the tunnel? How did you get over the inability to write a simple variant of a simple project?

Was it worth to persist and why?

9 Upvotes

32 comments sorted by

View all comments

Show parent comment

0

u/Exact_Ordinary_9887 Jul 17 '25

Pursuit which query selector I should use? there are 10 if I am not mistaken.

I need DOM related, but which one?

Can you see how your advice is missing the target?

1

u/GetContented Jul 17 '25

I think perhaps you might have missed some of my suggestion.

As I said... check in Web.DOM's API that querySelector is there.

If you search in pursuit for querySelector, yes you'll find 10, but if you then look at where they are in the results and see ones that are within that module, as I said. You'll find there's only one in Web.DOM. It's been moved to a sub module called Web.DOM.ParentNode by the looks of things. That's still within Web.DOM.

1

u/ruby_object Jul 17 '25

https://github.com/bigos/Pyrulis/blob/3cd62b640b392db711c2bf375b7e84aaa38c9d97/Purescript/parameters-and-configuration/second-attempt/src/Main.purs#L37

We have lift off!

to make matters worse, the answer was here:

https://book.purescript.org/chapter8.html

Why did nobody point me to the right page and fragment?

I spent 4 days on that!

1

u/ruby_object Jul 18 '25

But in the end I had success.

1

u/ruby_object Jul 22 '25

Trying to figure out how to have a working HTTP POST request took me days. Maybe I have proven I can pick up the basics at a very slow pace. However, I would like to know where I can have a better experience. The beginner level examples are lacking.

While I eventually found the cookbook, adapting the example took way too long.

0

u/Exact_Ordinary_9887 Jul 17 '25

1

u/GetContented Jul 17 '25

Why are you looking in Halogen?

1

u/GetContented Jul 17 '25

Yeah that's using the library I'm suggesting you use. You can use that if you like.