Hacker Newsnew | past | comments | ask | show | jobs | submit | erinan's commentslogin

It's not that bad, I'm on my second Elixir job in 3 years and in Asia which is even harder to find.

There are a good amount of jobs in the US or in Europe but you have to actively look for them...

I can however say that working with Elixir has been really pleasant and even enjoyable, and I'm not someone who codes outside of work. I'd definitely recommend it!


Whether it's a good idea or not really depends on your app, what you're trying to do, and who your users are.

Now if you want to avoid round trips to the server for interactions such as opening a modal, you can!

There are at least two ways to handle this - Javascript hooks that let you attach JS to your DOM, or the light AlpineJS framework. The latter is a perfect fit for Liveview and it's part of the unofficial go-to stack name PETAL - Phoenix Elixir Tailwind AlpineJS Liveview.


This has most likely to do with the codebase itself rather than with Elixir or Phoenix in your case.

And having to go through a few files to understand how a request is handled is not out of the ordinary in an app, especially if it's grown over the years?


Tbh Phoenix has a lot of boilerplate and some... Opinions that make the codepath slightly more complicated (often for good reason... that might not apply to all use cases) in the default project.

For example:. What exactly is the distinction between an endpoint and a router?


Endpoint == instance of phoenix webserver. Changing things in the endpoint gives you WAF-like control and you can do some early footwork here and store useful data in conn[:private] for you to use later in the modules called in your router

You can have multiple routers. I just built a thing where foo.com uses one router for the main site and *.foo.com is something else.


Point is, they are just plugs. You can put routes in an endpoint, it'll work just fine. The distinction is just a -often useful- prescriptive opinion by Phoenix. (Plug does not split between endpoints and routers)


very true, but the abstraction is pretty useful


it's useful if your project gets very large. It is a non-negligible cognitive cost when your project is very small and you are new to Elixir and Phoenix


Phoenix with Liveview is so good - not a solution to all the frontend problems but there's something about it that really feels magical.

I've recently also played around with adding AlpineJS to it and it solves some of the issues I was having with LV.


2-hour commute? I'll take the pay cut anytime, like is too short... (and maybe start looking for another job, easier to do with all that "extra" time)


Yeah no way I'm doing a 2 hr commute just for a 10% higher pay if there's another option available. That's months of life gone just on commuting that can be regained by paying 10% of pre-tax income? Seems like a no-brainer. Time is money.


It depends a lot on the mode of transportation. The Seattle employee referenced in the article may commute by ferry, which is about as relaxing of a commute as possible. The Seattle ferries are very nice; you can sit in a booth and eat breakfast and read the newspaper. Here's a photo of what it looks like: https://www.nytimes.com/2012/04/01/travel/vashon-island-near.... I'd totally be willing to do that for an hour every morning and evening.


But would you do it for 4?

I thought when people said they had an X hour commute they typically meant that they traveled for X hours to work and X hours from work


Good point. Where I am, people usually use "X hour commute" to mean the full amount in a day.

I wonder what percentage of people interpret it to mean one way vs. both ways.


Yeah I was wondering to what degree it is a regional thing. I'm from Australia and most people seem to mean it one way, but I've been wondering how many times I've misunderstood people online


We should probably assume that people commute via car unless noted otherwise, since it is by far the most common method.


Generally speaking, I agree, but for three example locations that were given in the article, that's not the case. Google's offices tend to be in major cities, especially more liberal ones, and those often have good public transit. Both Seattle and NYC have more people who commute to the city center via public transit than by car; I'm not sure about the numbers for SF.

I agree 100% that 2 hour commutes are crappy, but a 2-hour commute on a nice form of public transit is very different than 2 hours of being stuck in traffic and stressed out.


I would too, but if you've committed 100% of your income to expenses, you don't have that freedom.

Another argument for saving a little each month.


Sure but in this scenario it's a high earning google employee. I'm sure there's something they can cut back on.

For anyone average or lower earning, a 2 hour commute would cost you at least 10% of your income anyways (after tax).


Some individuals have routines built into the commute that aren’t necessarily swapped when working from home.

I read my email/catch-up on slack/read the newspaper during my 45 minute commute in the morning. While wfh I spend the time doing something pretty similar.


Commutes wouldn't bother me if I could consider them work time and get paid for them. Instead, they're uncovered overhead costs of work I have to pay daily because I'm driving. That's why the more WFH I get, the less lost time I have driving, fuel/car maintenance/value depreciation costs, less time preparing (I just do hygiene at home, no dressing up to present myself because pajamas are great). The savings have been adding up in both time and money.

Even if there was a great public transit option for my commute, I'd have to focus on aspects of work I could do because I get motion sickness pretty easily. Reading a laptop on a moving bus, train, or whatever is going to have me dizzy with a massive headache, then a lost hour recovering when I actually arrive. I do envy those who have the opportunity and capability to do this though.


For me it was principle more than anything. As a programmer I know I can do my job anywhere, and I know my team can do their jobs anywhere. So coming into the office always sucked because you knew this work could just as easily be done at home without having to waste all morning getting ready and commuting.


I think for a lot of workers being coerced/forced back to the office, there will be a lot of resentment. In my company, only part of the IT staff will be in the office, the majority look to be fully remote. That will breed so much conflict/antagonism/resentment that management seems oblivious to.


That sounds like the commute is really mostly work time then, right? Do you get to clock in/out 45 minutes late/early?


Yes, I usually leave at 9:15 arrive around 10 and leave around 5 or 6. As a software engineer my deadlines etc don’t lend themselves to a strict 9-5 approach.


That's not so bad then. I don't know many (any!?) places that would let their teams count that though, so glad to know some places do.


The big difference is that I’m visibly working during the commute. Given the nature of the train, the only activities I can’t do are coding and attending a meeting where I am an active participant.

The latter limitation will probably end soon with improved ML based background audio removal.


So you're working 9+ hours daily, given the time on email/slack during your commute? I'm not sure that's better than the people using their commute for audiobooks or whathaveyou, since that's at least personal time.


Presumably there's a lunch break in there.


If that includes an hour long lunch break, then the parent is basically just saying their employer pays them for their commute (especially since it sounds like they take the train or similar, and that probably is covered by their employer as well). Pretty sure most people who object to commutes do so because that time is uncompensated (and that people who demand them back in the office expect them in the office 8 hours a day), putting this into a squarely different bucket


Pretty sure you're wrong. If you drive, the commute can be a stressful waste of time.


The parent isn't driving.

But, sure, let's go with that line - if you are salaried, and you have an hour each way commute, and your company okayed you working 6 hours a day (since your commute is 2), and they also paid you extra for mileage (to offset fuel and wear and tear), are you saying you'd object as strongly as the people objecting to those 2 hours ON TOP of 8 hours in the office, with no compensation for mileage?

Because that was my point; the general objection to commuting I've heard, and would raise myself, is that it is unpaid personal time. Not that it's just an unpleasant task that the company is compensating me fully for.


At first I was thinking "that's not safe while you're driving", then I realized you're probably not driving.


Aye this is done via train in the Boston metro area. Despite Bostonians love of MBTA complaints, it’s a completely viable means of commuting and few companies don’t build on major transit lines.


Depends on the commute mode. It sounds like these are people in expensive urban areas, so they probably have transit access. So if they’re commuting by train or bus the morning commute can be spent working and the evening commute streaming TV shows or scrolling through social media.


Is this supposed to be an argument in favour of the 2 hour commute? Because that still sounds like a miserable waste of time to me. I would take the pay cut, look for a new job, or move closer to work. No job in the world is worth putting up with that kind of a commute to me.


A 2 hour commute isn't necessarily good, but it's also not necessarily horrible. The Seattle employee referenced in the article might commute by public ferry, which is very pleasant. A 10-minute drive to the ferry terminal, 5 mins waiting for the ferry, a 30 minute ferry ride, 5 mins disembarking, and 10 more mins to the office is not bad. Repeat for the evening commute.

The ride is beautiful and the interior of the ferries are very nice; you can sit at a booth and drink coffee and eat breakfast. If you're lucky, you might see some orca whales while you're out on the water.


As someone who can do a 90-120 minute door to door commute into our city office or an event in the city, it's still awful. I did it about half-time for about 18 months at another company. I would get up at 6am to drive to the train station, get to the office by about 8:30, get home 7ish--maybe somewhat later if I grabbed dinner in the city.

Yes, I could read and so forth and it was better than driving, but it still meant I had maybe 3 hours to myself in the evening.

It's OK as a very sometime thing but I'd certainly prefer not to do it even a couple days a week.


I've been living upstate and commuting to NYC for the last ~10 years.

A pay cut going full remote would basically cancel out my commuting costs. I might end up with slightly more money in my pocket once taxes and snacks are accounted for.

That said, when things "get back to normal" I don't currently intend to apply for full remote. I didn't mind my commute two years ago. Maybe I will when I have to start doing it again.


totally. i did this back in 2009. 20% pay cut, to reclaim 50% of my day (in just travel time). And for that, they've got someone who rarely is off sick, isn't too bothered if work runs over my usual office hours...and I've rejected multiple "in the office" jobs for up to twice my wages.


Yeah, it would be a total no-brainer. Especially given that we're likely talking about a six-figure salary in the first place…


This is exactly right, I had a 1.5 hour each way commute before we switched to work from home last year. I calculated that I saved around AU$5000 a year just from not having to commute or buy food/coffee out let alone the massive time saved. Not to mention the reason I had such a long commute in the first place is that I chose to live further away from the city to save money and actually afford to buy a home.

Plus as you say the 15 hours a week I get back on average, is basically another part time job or contract work I could pick up if I really wanted to earn some more on top.


I just switched from a Python (with mypy) codebase to a full-time Elixir position a few weeks ago.

I thought I'd miss typing but due to the functional nature of Elixir and its pattern-matching, I found out that the code is much simpler to grok.

In this case I think that having readable idiomatic code trumps the need for typing.

If needed there is type hinting with @spec but it's not used very often (or mostly in libraries?).

I can definitely say that it's very fun and productive to work in a Phoenix mono-repo. The development experience is great and I'm really having fun programming again.


I know you're being sarcastic but I will definitely not miss those when working with Elixir......


That's me with Python... For some reason I find the documentation extremely cumbersome to navigate and parse. It's just so wordy and dense. And there are barely any examples - which is what I'm usually looking for instead of having to read a whole paragraph.

The Elixir documentation on the other hand is succinct and always features basic examples for every function. It's a joy to work with.


As a slightly opposing take, Django has the highest-quality and most comprehensive documentation I've ever seen for a web framework... Or open source project, for that matter.

Not very related to the parent comment, but just an interesting note.


I agree, Django docs put Flask to shame! Flask in general is more intuitive I guess, but the docs are not as good as they could be.


+1 for Elixir’s documentation. José Valim knew what he was doing when he made docs so easy and pleasant to create and view.

I always love it when a programming language has their docs available off-line and easily accessible. I grew up on Perl without an internet connection (or a GUI for that matter) so I got very used to the perldoc command. That is now the standard I expect. Elixir is one of the few languages that exceeds this bar imo.


I've been playing with the ast module in Python lately, and the documentation actually says to go look at someone else's documentation because it's better, which is a refreshing take.

Official Documentation: https://docs.python.org/3/library/ast.html

Green Tree Snakes: https://greentreesnakes.readthedocs.io/


The answer as often is... "it depends".

Should you run an unindexed query on every keystroke of a text input of a form for every user? No.

But if you're not a junior dev, you'll know not to do those things and you'll know to debounce the text inputs, plus maybe only query the DB is the input text is longer than n characters for example. And you'll use a GIN index at first in your Postgres DB for fast text search.

It might all sound a bit insane but I believe that everyone should give Phoenix/Liveview a try. That stack can scale and it works amazingly well even on a cheap Heroku dyno.


> Of course, I had to get all that info from thedonald.win because almost no-one else is talking about this.

This and the Twitter account that you linked is the usual "no one is talking about this! they are hiding the truth" rhetoric that has lead to where we are four years later.


Consider applying for YC's Winter 2026 batch! Applications are open till Nov 10

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: