• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar

I Like Kill Nerds

The blog of Australian Front End / Aurelia Javascript Developer & brewing aficionado Dwayne Charrington // Aurelia.io Core Team member.

  • Home
  • Aurelia 2
  • Aurelia 1
  • About
  • Aurelia 2 Consulting/Freelance Work

Aurelia CLI Is Now Webpack First

Aurelia 1 · March 21, 2018

One of my favourite Aurelia changes isn’t a new feature, nor is it a long-awaited bug fix or new tool: it’s the fact the CLI now supports Webpack by default.

Why is this a big deal? Previously, the CLI took a RequireJS first approach to bootstrapping new applications, meaning if you didn’t choose to customise your au new generated application, you would get RequireJS as your default bundler.

Now, there isn’t anything wrong with RequireJS as a bundler, but the issue with RequireJS is given its age there are issues dealing with different file formats, especially styles and static assets like images and fonts (which it cannot handle).

Whereas, Webpack can handle every single file format type in existence without blinking an eye. If you need to support it, either Webpack supports it out-of-the-box or you can download a file loader to add in support and a simple module rule definition from within your webpack.config.js file.

While RequireJS can handle CSS and Javascript (it’s showing its age even in this department), it cannot handle a lot of other formats, which is why the RequireJS CLI apps would use Gulp and some various build tasks to copy things like fonts and images.

The performance of Webpack in comparison to RequireJS? There is no comparison, Webpack might be more daunting, but it wins in speed (especially Webpack 4).

Dwayne

Leave a Reply Cancel reply

1 Comment
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
Tony
Tony
4 years ago

Nice – working on a angular over aspnet core app, and would like to explore moving to Anrelia (as an ex CM WFP person) – this will take the pain away… are you updating your book in-line with this?

0

Primary Sidebar

Popular

  • Testing Event Listeners In Jest (Without Using A Library)
  • How To Get The Hash of A File In Node.js
  • Thoughts on the Flipper Zero
  • Waiting for an Element to Exist With JavaScript
  • How To Paginate An Array In Javascript
  • How To Mock uuid In Jest
  • How to Use Neural DSP Archetype Plugins With the Quad Cortex
  • How To Get Last 4 Digits of A Credit Card Number in Javascript
  • How To Decompile And Compile Android APK's On A Mac Using Apktool
  • NBN Box Installed Inside of Garage, Where Do You Put The Modem?

Recent Comments

  • Kevmeister68 on Start-Ups and Companies That Embrace Work From Anywhere Will Be More Likely to Survive the Coming Recession in 2023
  • kevmeister68 on What Would Get People Back Into the Office?
  • Dwayne on PHP Will Not Die
  • Dwayne on How to Create a Blockchain With TypeScript
  • kevmeister68 on PHP Will Not Die

Copyright © 2023 · Dwayne Charrington · Log in

wpDiscuz