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

dumb question from someone re-entering the FE world: why is Vite necessary?

My understanding is it basically strips the type information using Go (IIRC) where your typechecking is then a separate step (without transpilation). So feedback is more rapid.

But, with tools like Deno or ts-node, where the type checking is apparently also off the hot path, why does Vite still exist?

Is it because it connects file monitoring with a dev server? Because it also somehow works non-js artifacts like CSS and image imports?

Ultimately, I've found the world of Vite + ESNext imports to be a world of frustration and pain. And, I really want to like Deno, and a lot of it is magical, but ultimately, there's just some splitbrain stuff going on with Deno's concept of a monorepo and their inability to commit to their public projects (e.g. Fresh) leaves me concerned it's risky to build on top of.

(ok, that turned into a rant, but there are some questions in there.)


It is also a bundler and minifier and dead code tree-shaker. It combines all your modules into one file (or a few) for production. In development it doesn’t do the bundling part (for now — with Rolldown[0] replacing Rollup[1] in the future, bundling will be fast enough to do the same in dev and prod).

It also serves as an integration point for other kinds of tooling that involves processing or generating code. For example, the latest versions of React Router[2] (which now integrates Remix's features) and Tailwind[3] are designed primarily to be integrated into projects as Vite plugins.

[0]: https://rolldown.rs/

[1]: https://rollupjs.org/

[2]: https://reactrouter.com/home#react-router-as-a-framework

[3]: https://tailwindcss.com/blog/tailwindcss-v4#first-party-vite...


> Is it because it connects file monitoring with a dev server? Because it also somehow works non-js artifacts like CSS and image imports?

Yes and yes. Also some pre-processing such as compiling JSX into JS.




Thank you. I was short on time and didn’t see a good result quickly enough


Know how many 9 year olds I’ve seen hit in the head with a baseball, while at bat? (Many. One kid on my sons team was hit in the head for four consecutive tournaments last fall.)

Always wear a helmet when you’ve got a bat in your hand.


I have an implementation function that computes N v7 UUIDs, sorts them, and returns them. This makes testing possible.

    Collection<UUID> generate(final int count);
I also have an interface that I can back with a RNG that generates auto incrementing values, sorts for testing, I have the experience of ints, but for production, my non-timestamp component is random.


This is madness.


You and I have a fundamentally different view about how to optimize education. Your view is probably great to cover the base case of people “checking out” of their children’s education, but my individualized view doesn’t care about the 90% but the child in front of me.

I’d also posit that this approach to education reduces overall attainment by dulling the edge of what the margin is capable of.


Contrarian take: I feel that copilot rewards me for writing patterns that it can then use to write an entire function given a method signature.

The more you lean into functional patterns: design some monads, don’t do I/O except at the boundaries, use fluent programming, then it’s highly effective.

This is all in Java, for what it’s worth. Though, I’ll admit, I’m 3.5y into Java, and rely heavily on Java 8+ features. Also, heavy generic usage in my library code gives a lot of leash to the LLM to consistently make the right choice.

I don’t see these gains as much when using quicker/sloppier designs.

Would love to hear more from true FP users (Haskell, OCaml, F#, Scala).


Annoyed this isn't available on the family plan.


It is. You can upgrade family members to Ultimate tier on-demand.


I don’t know much about the company or situation, admittedly. But this wasn’t the strongest claim:

> they said their probe involved data scientists who dug into computer code to understand how these algorithms set prices


I’m a father of two children, a nine and two year old, and none of us know how to play piano. I did play a woodwind for five years in and out of school, and did extracurricular music for many years - even from a young age.

Now, I’d like my son to learn piano as his first instrument. I imagine the theory and complexity of chords thrust on the pianist must be a good foundation for music in general - certainly I’m fine with my kids departures to any other instrument and mastery isn’t itself the goal.

Is this app the right tool? It doesn’t explicitly market to this segment. However, there are a number of other apps out there I’ve considered as well, including PianoMarvel mentioned elsewhere.

Surely, 1:1 lessons will be recommended - and I imagine they have their place - but I’d prefer to lean a bit harder into self-guided / app-guided and augment with a human tutor as necessary. My experience was that my tutored sessions were a bit wasteful (I wasn’t a disciplined student, and certainly wasted a lot of time and money).

My ideal setup is either an iMac or iPad and an electric piano.


Anecdotal, but maybe it'll help

I had a goal of introducing my kids to piano, and also wanted to pick it back up myself (I'd been forced to as a kid and hated it, never progressed beyond beginner).

I got myself a casio privia (it's a costco special 88 weighted keys, was the reddit recommendation for beginners at the time). Then paid for lessons with a teacher for my family which by far outweighed the cost of the keyboard.

About 10 years later: rest of family have given up piano, they didn't progress far, and i didn't do any forcing; but it was nice to hear them play when they did. I've kept it up although progress is very slow.

I think my feelings are: - I could have spent more on the piano (my dad got a significantly more expensive piano, and it is more pleasurable to play): quieter keys, better action on the keys. - I feel pretty good about how far my the rest of my family progressed, and am happy that i didn't push - I feel like a teacher somewhat forces you to keep practising even when you don't want, and maintains some progress, I don't think I'd get this from an app.


The teacher isn’t there to teach - you could do that on your own with enough time and energy. The teacher is there to preserve your passion by making sure you don’t get bogged down in easily-fixable troughs. They will hopefully have knowledge of music such that you’re always excited to play something new rather than feeling like you have to dig through a composer’s works to find something worthwhile. They provide accountability for your practice and validation for when you do well.

Ideally, you should use yourself as a guinea pig to test out the teachers in your city to find one that’s best for your kids. In reality, dumping your two-year-old on your wife to do that sucks for both of you. Your local music shop can help steer you away from teachers with bad reputations in your city.

https://youtube.com/@cedarvillemusic?si=BiZ9tF9fYcEkxcMw

This guy has thorough answers to questions no one wants to ask (e.g. Are my hands too small? What if I’m playing for others and I forget how the piece goes? Why does improvisation feel impossible to understand? How long should I practice? Should my hands hurt?).

https://web.archive.org/web/20200118023642/https://howmusicw...

This is the best explanation of music theory I’ve found and I’ve looked everywhere.

https://www.reddit.com/r/musictheory/wiki/core/modes/

The FAQ on the music theory Reddit has answers to questions that are largely impossible to find elsewhere. “What are modes?” is one of those questions.


In nearly any instrument it's very important to get the technique right from the start. It's incredibly easy to catch bad habits which then are much more difficult to unlearn, and will make your progress much slower and frustrating. So actually it's the other way around: pay a teacher to help him start, correct his posture/technique/etc, then later on you can wean off and continue on your own :)


I suggest an electronic keyboard with weighted keys and the free Mayron Cole lesson books.


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

Search: