purescript-halogen / purescript-halogen-template

Template project for getting started with Halogen
Apache License 2.0
128 stars 56 forks source link

Redundant rm dist in build-prod package.json #40

Closed stevenyap closed 1 year ago

stevenyap commented 1 year ago

Hi I was picking stuffs from this repo for my own halogen project when I noticed there is a redundant rm -rf dist as below:

https://github.com/purescript-halogen/purescript-halogen-template/blob/9cc04eacd187026e782e6d0e26368f179ad0a3a5/package.json#L12

Is this a mistake? Or there is something underlying which I am not aware?

or should it be this:

 "build-prod": "rm -rf prod && mkdir -p prod && cp dev/index.html prod/ && spago bundle-app --to prod/index.js && parcel build prod/index.html" 

Thank you.

garyb commented 1 year ago

Yeah, that sounds right to me!

I've not kept my eye on this repo for a while, but should probably give it a look over - I think the use of parcel is a leftover from before the compiler supported ES modules, I'd use esbuild instead.