blog.negative9.net/contents/articles/fuck-webpack/index.md

1.9 KiB

title author date template
ES6 is Evergreen, so Fuck Webpack geoff-doty 2017-12-24 article.jade

I know. I know. Blasphame, but I really hate Webpack, not the idea of it but what it turned web development into - a bloated tangled mess of shit you don't need.

Webpack

Webpack became the defacto go-to solution to get the latest es6 javascript language functionality into a developers pipeline via transpilers like Babeljs and support the overly bloated non-standard web component soultion as the ReactJS framework (batteries NOT included). Sure Webpack does more or can do more, but in the end developers just want to develop with es6 features.

This is a web developers handycap and reminds me of those old drug commercials

I work more, so I can do more drugs, so I can work more...

it becomes

I work more, so I can add more configuration, so I can work more...

PULL THE FUCKING PLUG!

Stop getting distracted by the shiny future that may never come, and focus on the here and now. Here and now we have native es6 language support in all evergreen browsers.

No webpack.

No configuration.

No bullshit.

How Does it work

Everything starts with your index.html page, or what ever html page your building, and you turn your script includes from this

    <script src="mycode.js"></script>

into this

    <script type="module" src="mycode.js"></script>

and those lazy import statements you have that dont include the extension

    import Code from './src/Code';

should have the extension

    import Code from './src/Code.js';

and everything is right with the world and we can find peace and happyness for all.

FUCK WEBPACK!