QubitProducts / slapdash

A lightweight JavaScript utility belt with native method override protection
http://npmjs.org/packages/slapdash
MIT License
3 stars 1 forks source link

v0.6.0 #28

Closed jimmed closed 8 years ago

jimmed commented 8 years ago
jimmed commented 8 years ago

@alanclarke @KidkArolis @oliverwoodings Call for comments before I merge + publish?

KidkArolis commented 8 years ago

So does the build step concatenate the src files into 1 file? That's pretty cool.

Does npm contain the built bundle? We don't run npm scripts when installing packages in ssg, so this needs to be prebuilt before publishing to npm.

Also - npm postinstall script is not what you think it is ... @oliverwoodings ?

oliverwoodings commented 8 years ago

postinstall runs after npm install is executed. I think you might be looking for prepublish @jimmed

KidkArolis commented 8 years ago

@oliverwoodings why did we have problems using postinstall for qubit-styles?

oliverwoodings commented 8 years ago

Oh because of dependency resolution. If your postinstall script requires a module (e.g. in this situation we were using postcss-cssnext) and that module has it's own postinstall script, npm won't wait for that dependent postinstall script to finish before running your one if the dependency is deduped.

jimmed commented 8 years ago

So does the build step concatenate the src files into 1 file? That's pretty cool.

Yup! I'm quite proud of it. It's janky as it makes certain assumptions about the code (i.e. imports first, exports last), but it does produce a significantly smaller/simpler bundle than webpack.

postinstall runs after npm install is executed. I think you might be looking for prepublish

Oh right! I'll add a prepublish step instead, and make sure codeship builds the dist manually.