developit / preact-redux

:loop: Preact integration for Redux (no shim needed!)
https://npm.im/preact-redux
MIT License
288 stars 27 forks source link

Named exports #10

Closed piuccio closed 7 years ago

piuccio commented 7 years ago

Same a #4 (kinda) and a fix for #9

This code exports both a default and named exports

developit commented 7 years ago

This is awesome, will try to look at it and get it merged tonight. If it works well I think we'll apply the same technique to Preact.

anthonyjgrove commented 7 years ago

updates?

developit commented 7 years ago

I need to merge just the src changes here, the build stuff will break commonjs exports.

ezekielchentnik commented 7 years ago

I think we're going to need two rollup configs.

one for an es bundle (preact-redux.esm.js), the other for a pure UMD bundle (dist/preact-redux.js); this PR currently breaks commonjs exports - unless we are ok with forcing commonJs consumers to require this module using the default keyword e.g.

const preactRedux = require('preact-redux').default

@developit not sure if you've concluded the same (maybe you found another solution). If so i can tack onto this PR with what I'm suggesting

cheers

ezekielchentnik commented 7 years ago

see PR #15

developit commented 7 years ago

Fixed in 2.0.2.