Live data from Hacker News

Building a Startup on Clojure

wobaka.com

171–180 of 215 posts

Re: Building a Startup on Clojure

#171
post #89

Ah clojure. It's all fun and games until five years down the line, you've had 100% dev churn, and you have a 100kloc codebase that nobody understands, full of functions that don't give the slightest hint of the shape of the data they're processing (it's all lists!) yet down the bottom of the callstack there's some function that'll explode if the map doesn't have whatever magical key it expects. If you're really lucky…

>>> full of functions that don't give the slightest hint of the shape of the data they're processing

This is a big problem with Dynamic languages. If you are new to the codebase, you have no idea of what the shape of the data is, what to expect etc.

Re: Building a Startup on Clojure

#172
post #5

Question for Clojure's pros: as a designer I started programming javascript for a long time, now I can do my own APIs on Node easily, would it be hard to do APIs in Clojure? Can you recommend me a video course for learn it?

Jacek Schae's courses on reitit for the backend and reagent, reframe for the front end are very good

https://www.jacekschae.com/

Re: Building a Startup on Clojure

#173
post #50

Earlier quoted context omitted.

I kind of agree with you. I used to work with Common Lisp in a Desktop App (Nyxt browser). I had some fun playing with Racket. And I love Emacs. So, I am already into the Lisp idea. But, I was kind of disappointed with Clojure which is new in my life and has been used in my current job. Maybe you have a backend bias in your testimony? I have been working with ClojureScript (re-frame and reagent) on front-end stuff an…

Don't know about your exact environment but I've structured my code so most of it is in .cljc files which can be evaluated in browser and on server. This allows me to evaluate/test/run things easily in the emacs repl. For view code I think hot reloading has been a great thing with Clojure/Script too. Everything is reloaded properly and the state remains.

You can have a cljs repl as well, and you can open an alert in the browser from it like you'd do in the console

Re: Building a Startup on Clojure

#174
post #82
post #2

If I was choosing a language to base the tech stack for a startup on these days I'd be very reluctant to pick anything that didn't have a local user group. Slightly more esoteric languages that enable you to write better code faster are brilliant, but if you're successful enough to grow quickly, or you can raise funding, you'll need to hire devs relatively early on. If you've chosen a stack that's too esoteric then t…

How long does it take for some non-Python dev to become a Python dev? One week? Two?

Learning a language like Python is easy enough, but the hard bit is actually unlearning the language you came from. If you give a JS dev a couple of weeks to learn Python they'll probably succeed, but their code will be 'python syntax written with a JS thought process'. The code will work but it won't be good code. Sometimes that's fine, but as the foundations of a startup?

Getting to the point where you're writing good Python and taking advantage of what the language provides, knowing the ecosystem, and building things that other Python devs won't look at and think "Wtf?" takes much longer than weeks.

Re: Building a Startup on Clojure

#175
post #126

What does everybody think here of C#? I've just made foray into it and I like it a lot compared to Python, Java etc. It almost feels like Kotlin, but with certain even cooler properties.

C# is great. You get: - Tons of developers know it - Tons of Java developers can be made to know it with ease - A good default IDE experience within VS and VSCode, and a JetBrains product if you prefer it. - A good LSP implementation with OmniSharp if you don't want to use an IDE. - ASP.NET, a good default Web framework. - NuGet as a package manager with tens of thousands of packages. - Better than java reflection an…

If you want to make lists

- you have to

- skip a line

- between each bullet

- item

Re: Building a Startup on Clojure

#176
post #5

Question for Clojure's pros: as a designer I started programming javascript for a long time, now I can do my own APIs on Node easily, would it be hard to do APIs in Clojure? Can you recommend me a video course for learn it?

I learned by reading through a book, then working through problems on https://4clojure.oxal.org/ . If you've got JS experience it won't take too much effort to pick up. Don't get too carried away with forming the perfect tail recursive pure functional monad or whatever. Get into just doing what you're trying to do quickly, then after you're competent, read other people's code to correct your style.

I always go pragmatically, I don't focus too much on ultra complicated architectures, but more on get things done.

Re: Building a Startup on Clojure

#177
post #89

Ah clojure. It's all fun and games until five years down the line, you've had 100% dev churn, and you have a 100kloc codebase that nobody understands, full of functions that don't give the slightest hint of the shape of the data they're processing (it's all lists!) yet down the bottom of the callstack there's some function that'll explode if the map doesn't have whatever magical key it expects. If you're really lucky…

What worries me the most about clojure and languages like it, is that seems to be for people who want to be clever with how they write programs, when that is the opposite of what I want from people I work with.

As opposed to the paradigms of beautiful design that are Java codebases.

Re: Building a Startup on Clojure

#178

Earlier quoted context omitted.

As the saying goes, a bad workman always blames his tools. You can make a mess in any language, and Clojure is no exception. There are plenty of ways to mitigate the problems the author describes. A few of these things would be having coding standards to ensure that code is written in a way everyone is comfortable with. This also covers things like adding schemas and documentation for maintainability. Doing pairing a…

You can make a mess in any language, yes. But some languages tend to produce more messes than others. If your tool is mis-used more than other tools, at some point, it's not the fault of the users.

I’ve personally had to deal with far more and worse messes in Python, Java and Javascript than I ever did in Clojure. (Started using Clojure ~13 years ago, but have been in jobs that use the other languages I’ve mentioned in that time too, not always exclusively using Clojure, although there were periods where I was).

I have mentioned a few times in the past, on HN and Reddit and elsewhere, that my biggest personal dream language wishlist item is “Clojure but with static types”, however, while that’s something I dream of having, it hasn’t held me or the language back in any meaningful way. The thing that makes Clojure less mess-inducing in my opinion is largely the fact that it’s data is immutable by default. An immutable-Python would be something I’d be interested in trying.

Re: Building a Startup on Clojure

#179

Earlier quoted context omitted.

You can make a mess in any language, yes. But some languages tend to produce more messes than others. If your tool is mis-used more than other tools, at some point, it's not the fault of the users.

I’ve personally had to deal with far more and worse messes in Python, Java and Javascript than I ever did in Clojure. (Started using Clojure ~13 years ago, but have been in jobs that use the other languages I’ve mentioned in that time too, not always exclusively using Clojure, although there were periods where I was). I have mentioned a few times in the past, on HN and Reddit and elsewhere, that my biggest personal d…

> I have mentioned a few times in the past, on HN and Reddit and elsewhere, that my biggest personal dream language wishlist item is “Clojure but with static types”, however, while that’s something I dream of having, it hasn’t held me or the language back in any meaningful way.

Sadly, Rich Hickey has always been pretty opposed to typing in Clojure. Enforcing values to be not null is basically table stakes for typed systems, and yet he doesn’t seem to think it’s valuable or feasible,

https://github.com/matthiasn/talk-transcripts/blob/master/Hi...

It does make me sad every time I have to deal with macro systems in non Lisp languages (Julia, Scala).

Re: Building a Startup on Clojure

#180
post #112

Earlier quoted context omitted.

deps is more flexible, but I you just want to run a repl, build and deploy code then lein still works fine. I usually default to leiningen: I can't be arsed to spend time configuring deps to do what lein does out of the box. (For example: building an uberjar)

I was lost when I moved to deps from lein, but just forking and cloning https://github.com/practicalli/clojure-deps-edn as $HOME/.clojure solved the problem - this base deps.edn contained all the aliases I needed - creating a new project, searching and adding dependencies, hooking up data inspectors like portal or reveal, testing, code coverage, benchmarking, building uberjar etc. Moving to deps also introduced me to…

To me it is kind off crazy when a build tools needs some 3rd party config library to make it usable.
Post reply on HN