Fork me on GitHub
#other-languages
<
2016-07-07
>
martintrojer07:07:37

we are well into a large-ish cljs codebase to Elm rewrite. I couldn't be any happier.

martintrojer07:07:13

very liberating to get rid off all this legacy cljs šŸ™‚

cfleming08:07:11

@martintrojer: Is your happiness shared by others on your team?

martintrojer09:07:49

smallish team, 3 devs, but absolutely

martintrojer09:07:10

designers also happy writing html in the Elm markup language

lewix14:07:59

That's quite interesting

lewix14:07:09

I wish they had elm in the backend working

scriptor14:07:38

@martintrojer: any concrete examples of when Elm's been better so far?

lewix14:07:29

scriptor: I just looked at elm for a day, and my first impressions blew my mind away. namely, the error messages. (I think it's underestimated in the clojure community). I'm not surprised Elm is pleasant to work with

scriptor14:07:28

@lewix: agreed regarding error messages, hopefully having clojure-spec used in core fns will help

scriptor14:07:26

I've been trying to keep track of specific cases in my code where a stronger type system might've come in handy

scriptor14:07:05

because I'm somewhat jaded of hand-wavy phrases like "easier to reason about" and "catches errors at compile time"

martintrojer14:07:02

@scriptor: gonna sound cheesy, but its better at everything that really matters; productivity, code quality, team work

scriptor14:07:16

I have a feeling the same thing was said when clojurescript was originally chosen

lewix14:07:20

martintrojer: I heard that most elm developers use Elixir. I wonder if they have the same experience with Elixir in the backend

martintrojer14:07:38

I'm sure Elixir is good, but I'm not looking to replace Clojure (in the backend) with another dynlang

lewix14:07:42

martintrojer: let us know when you make your pick (curiosity talking)

martintrojer14:07:17

we are thinking on going much more microservices. So Purescript + Node is looking good atm

scriptor14:07:25

purescript looks interesting

lewix14:07:41

martintrojer: I hate you. your praise of Elm make me want to jump into it right away...I guess I'll be buried in yet another language for the next couple of weeks. shame on you

lewix14:07:05

scriptor: I'm looking for good presentation about purescript

scriptor14:07:04

@lewix: let me know if you find one, I've only briefly looked at it

scriptor14:07:17

hah, if you wanna go all out, apparently Idris has a JS backend

martintrojer15:07:36

the purescript book is good

martintrojer15:07:46

Phil keeps it up to date aswell

lewix15:07:50

martintrojer: : even for people with no haskell experience?

lewix15:07:57

does anyone use purescript in production?

lewix15:07:41

markmandel: also why not use purescript back end and front end

markmandel15:07:11

I've never used purescript, so I don't have an opinion?

scriptor15:07:31

I think lewix meant to highlight martintrojer

lewix15:07:30

markmandel: right. sorry wrong person

martintrojer15:07:21

Purescript is a bit like "haskell, the good parts"

markmandel15:07:17

No worries - interesting discussion though!

lewix17:07:55

I guess purescript is still new, there's no much blog post about it..and a full blown app

seancorfield17:07:48

The PureScript site has some pretty good material on it thoā€™ http://www.purescript.org/learn/ and Bodil Stokke did a great talk based on it at Strange Loop 2014 https://www.youtube.com/watch?v=yIlDBPiMb0o

seancorfield17:07:59

And if you want the whole Haskell language compiling to JS: https://github.com/ghcjs/ghcjs

lewix17:07:32

what! 2014..is it that old

scriptor18:07:39

that's young in programming language years

martintrojer18:07:58

the book is the best PS resource, https://leanpub.com/purescript

martintrojer18:07:14

Blogs, talks, who cares? šŸ™‚

lewix20:07:28

seancorfield: you know Purescript too? when do you find the time to learn all those languages...

seancorfield20:07:17

@lewix: Nah, I havenā€™t played with PureScriptā€¦ I donā€™t really see the point when thereā€™s Elmā€¦ But mostly I do zero work in the browser anyway.

montanonic20:07:18

I find PureScript to be a lot to digest. Not sure if they've simplified things recently, but Haskell/PureScript have a tendancy of presuming familiarity with essentially cutting-edge functional programming techniques to accomplish most basic things. This is coming from me having spent 8-9 months with the languages, albeit as my first ones.

lewix20:07:36

montanonic: your first language was purescript...interesting šŸ™‚ it's definitely not the traditional path

montanonic21:07:57

Elm is focused on tooling and simplicity, the FP stuff is a means to an end. I think this is the right decision.

montanonic21:07:26

Rust is focused on community and learning resources, this has also been the right decision. Haskell and PureScript don't have stories for that yet, I don't believe; this will hold them back.

montanonic21:07:53

lewix: First language was Haskell, and by extension, PureScript once I tried to delve into front-end stuff

lewix21:07:57

what's clojure story?

montanonic21:07:24

Really smart language designed for getting work done, from what I can tell.

lewix21:07:27

definitely not learning resources, which hold them back

lewix21:07:11

montanonic: very well designed

lewix21:07:04

montanonic: What made you learn haskell as a first language?

montanonic21:07:31

I've only been Clojuring for a week (a very intense week), and I've really grown to appreciate Lisp, and think that its emphasis on thinking about almost everything as just simple data is an amazing lesson that I will take with me to every language

montanonic21:07:33

But debugging it is a pain in the ass. One tiny mistake, done. I have to consistently break up my functions into tiny components and test in REPL. I love the live-feedback routine, but it is clear to me Clojure isn't a silver bullet, even though it is a very excellent language

lewix21:07:06

I like clojure to a fault; I feel like the language superiority is also a trap...you want to believe that you're more productive (after playing with it for about a month on weekends, I don't think it'll make me more productive). You want to stick with it through bad and good times.

montanonic21:07:10

lewix: I naturally gravitate towards things that are more obscure. Haskell looked deeply different from everything else; seemed like the smarter approach

montanonic21:07:44

I started with Scala a little over a year ago, tried out Haskell a few weeks into that, and realized that it was actually easier than Scala, contrary to my presumptions. Then I just went with it.

lewix21:07:01

interesting

montanonic21:07:30

Yeah, speaking of productivity, I don't think I would be more productive with Clojure than I would be with Elixir for building websites, IMO

montanonic21:07:46

only because Erlang is essentially built for writing servers

montanonic21:07:57

that's the default mode: fault tolerant scalability

montanonic21:07:50

But that's just me, I'm very unfamiliar with the Java ecosystem, so I can't leverage it like a lot of other Clojure people can without significant effort.

lewix21:07:07

Erlang was built for communication if I'm not mistaken

montanonic21:07:48

Yes, telecommunications. Which, if you think about it, is what the internet is, just with different protocols.

lewix21:07:16

It doesn't mean it solves all problems

montanonic21:07:22

Definitely not, I concur.

scriptor21:07:42

this paper reminded me of some of the discussion here lately, albeit it's about Scheme vs Miranda

lewix21:07:00

I think I'm kind of still looking for a language that suits me...

montanonic21:07:13

Micro-service style architecture is exactly how Erlang has built its libraries though. So the recent fad towards that style of modularity has been best practices in Erlang for like two decades

lewix21:07:27

interesting

montanonic21:07:39

And when I say Erlang, I mean Erlang/Elixir

montanonic21:07:04

they complement each-other, Erlang is the parent, Elixir is a fancy new wrapper on top of it with a much larger community; just to clarify for anyone not clear on that

lewix21:07:15

montanonic: The Elixir team has a strong Ruby background, so it's being influenced by ruby somehow

montanonic21:07:48

100%; a lot of Elixir code is not idiomatic Erlang-style, which is usually a bad thing

lewix21:07:15

As a ex-rubyist, (lovely language) I don't think I want more ruby(aka elixir) for my pet projects

montanonic21:07:18

that said, the tooling is great, and the core Elixir people definitely know Erlang well.

montanonic21:07:53

Fair enough. I will say that the illusion of Elixir is that it's anything like Ruby when it comes to how to write it

montanonic21:07:21

It's a very thin wrapper on top of Erlang, which is about as different of a world as something like Haskell, IMO. Well, different, but, I will clarify: definitely not as complex and hard

lewix21:07:50

montanonic: are you learning both clojure and elixir at the same time?

montanonic21:07:49

I've dabbled with learning 7 languages in the past two months. Erlang, Elixir, Elm, Clojure, Rust, Kotlin, Java. I've focused by far the most on Elixir and Erlang, with Rust and Clojure coming up.

montanonic21:07:59

So, I don't really know what I'm learning right now, lol

lewix21:07:39

I'd love to see a list of the languages ranked in order of the best error messages

montanonic21:07:45

The problem for me is that I don't know what problem I want to solve at this point. I'm not sure I like web development that much, but I also think it's extremely powerful.

lewix21:07:46

(outside of rust and elm)

lewix21:07:43

id probably learn the one on top

montanonic21:07:07

Yeah, honestly, they aren't that great beyond Elm and Rust, and Rust has a steep learning curve with the error messages, as far as understanding why they are happening

lewix21:07:08

montanonic: try mobile?

montanonic21:07:02

lewix: I've actually been leaning towards low-level stuff recently. Instead of building websites, maybe, build a better internet. So, Rust.

lewix21:07:05

from what I heard so far while talking to different people golang is up there in terms of error message amongst most common languages

montanonic21:07:20

Oh, that's a good point. Go probably is very solid on that front.

montanonic21:07:53

Although it still seems that they haven't figured out how to solve Generics yet, and I hear using generics gets rid of compile-time checks. That said, there are probably still sufficient runtime checks

montanonic21:07:32

What I've experienced is that if you give up static-typing + types, you won't have good error messages, period; everything is just stack trace

lewix21:07:58

what about java then?

montanonic21:07:00

So literally every dynamic language I've used, it's just not great on that front. That said, it's much easier to just run your code and see the output

lewix21:07:10

error messages still suck

lewix21:07:37

montanonic: ruby wasn't as bad as clojure in terms of error messages

montanonic21:07:44

Kotlin on the IntelliJ platform had very solid error messages, but I'm sure that won't save you from mutable state spaghetti

montanonic21:07:56

lewix: good point, I forgot about that

montanonic21:07:07

Let me clarify now that I understand the distinction I was going for:

montanonic21:07:13

dynamic languages on a VM

montanonic21:07:30

Because Elixir, like Clojure, is also on a VM, and the error messages are usually just stacktraces

lewix21:07:06

have you considered node.js/

lewix21:07:39

or you're very opinionated about functional languages

montanonic21:07:57

Coming from Haskell, node.js was a dirty word. I don't have a high-opinion of node because of that on instinct, but I'm much more open now to trying out new things and experiencing instead of judging

lewix21:07:11

js sucks but ey it does the job

montanonic21:07:40

The fact that the most obvious way to write a loop in JS doesn't work still bothers me

montanonic21:07:26

lewix: do you use node.js much currently / in the past?

montanonic21:07:33

what's your current tech situation look like?

lewix21:07:34

I realized that going for very well designed language is definitely a trap in itself sometimes...you're definitely bias because of the language itself but not necessarily everything else that comes with it that makes you productive day in and day out

montanonic21:07:01

yes I completely agree with that

montanonic21:07:20

I've favoured languages over ecosystems too much, potentially

lewix21:07:21

so I try to force myself not to be attracted by the new and shiny well designed language

lewix21:07:06

C -> visual basic -> actionscript -> java -> C -> a bit of python -> ruby -> javascript -> js framworks (if it counts at all) -> clojure --> looking for a togoto language (my story line)

lewix21:07:25

I'm still new with clojure

lewix21:07:15

and java doesn't count that was in college (everybody learned it and forgot it)

montanonic21:07:22

slight tangent: At this point in my life, I'm interested in working in any language as long as it gets the job done, but specifically, only if that job actually seems like it will be a meaningful project, and not just easy/quick cash. I probably need to get more experience before having the chance to work on projects that I can be passionate about, but if I can start there, that'd be superb. Right now theres a lot of people in the Rust community who are working on truly interesting projects, which is making me more and more drawn to it. Likewise with Elixir, but, Rust is an even more cohesive community.

montanonic21:07:48

haha, gotcha; I definitely think JS frameworks count

lewix21:07:18

what kind of projects are you looking for?

lewix21:07:27

maybe we should design our own language lmao

montanonic21:07:03

It's really hard to say what I'm looking for because I believe that I just need to understand more about technology before I can really have an informed opinion

lewix21:07:48

we're very similar oddly enough. I tend to spend a lot of time researching before making a decision...it's not always a good thing I guess

montanonic21:07:34

that said, the two branches of things I'm instinctively interested in are: tech that is actually meaningful to people who aren't very privileged and that can help the hundreds of million who needlessly suffer in this world, and then the other branch would be stuff to do with cryptography, building a new web, building new currencies, contracts, stuff like that; blockchain, but I'm still naive about that stuff

montanonic21:07:30

I have the philosophical stance that most western countries are way, way, way wealthier than they (we) deserve to be, and I want to fight for a more balanced world, but, yeah, there's no obvious path for that, and that's a long term pursuit.