forestryio / create-static-site

Create static websites with no build configuration.
MIT License
136 stars 10 forks source link

Add support for common loader types in webpack config #32

Open chrisdmacrae opened 6 years ago

chrisdmacrae commented 6 years ago

Right now the webpack config is only processing JS.

What if I want to:


Calling all static site power rangers @ncphillips @zivbk1 @budparr @scottgallant

ncphillips commented 6 years ago

Let’s take a look at create React apps approach for some inspiration.

Maybe this should be another issue of discussion, but also note that they separate dev and prod webpack configs. I think this is the right approach. Duplication is easier to deal with then the insanity of maintaining one file that does both.

chrisdmacrae commented 6 years ago

I went through CRA's webpack configs and honestly, a lot of it made a lot of sense.

Pulled anything that wasn't specific to React and then customized it to a static build versus a React app.

budparr commented 6 years ago

It's so nicely commented.

ncphillips commented 6 years ago

Are you including the config to allow for JSX syntax @chrisdmacrae ?

chrisdmacrae commented 6 years ago

@ncphillips Sure am! https://github.com/forestryio/create-static-site/blob/remove-gulp/packages/static-scripts/config/webpack.config.dev.js