Live data from Hacker News

Please Stop Using Barrel Files

tkdodo.eu

1–6 of 6 posts

Re: Please Stop Using Barrel Files

#2
In my admittedly meagre frontend experience, large startup times for dev instances are terrible for my efficiency.

The worst was a spring boot app at work which would synchronously download the entire key vault, 1 secret at a time.

I switched that out to load lazily, and the app started almost instantly!

My teammates were quite happy with the new state of affairs

Re: Please Stop Using Barrel Files

#4
Is the term "Barrel file" somehow in common use? I've never heard of it (not a js dev though). I would expect some kind of "umbrella file", "public interface", "reexport facade", or something along those lines.

Re: Please Stop Using Barrel Files

#5
post #4

Is the term "Barrel file" somehow in common use? I've never heard of it (not a js dev though). I would expect some kind of "umbrella file", "public interface", "reexport facade", or something along those lines.

Yes it's common terminology in the modern js/ts ecosystem. It makes sense because your gathering modules into a single "barrel". We already have plenty of gang of four word vomit terms we don't need anymore.