Gbuomprisco / ng2-material-dropdown

Angular 2 Material-like Dropdown Component
MIT License
37 stars 54 forks source link

fix(aot): make the library work with AoT #39

Closed mattlewis92 closed 6 years ago

mattlewis92 commented 6 years ago

Hi there,

I know last time you were reluctant to merge my previous PR that fixed AoT as it had breaking changes and made the stylesheets external, so I'm back again with a less invasive PR this time that has no breaking changes and doesn't touch any source code (only tooling)

https://github.com/dherges/ng-packagr nicely abstracts everything away and make the whole process super simple.

cp ./dist/bundles/ng2-material-dropdown.umd.js ./dist/dist/ng2-dropdown.bundle.js is used to preserve backwards compatible for those using this lib with system.js where you have to configure bundle files for each lib. This could be removed in a future release as a breaking change if you wanted.

Also instead of npm publish, you now need to run npm run release to build the dist files and publish them to npm.

If you'd like me to explain anything else just let me know 😄 Also happy to make a similar PR to https://github.com/Gbuomprisco/ngx-chips if you're happy with these changes.

Supersedes #37

Gbuomprisco commented 6 years ago

Hi @mattlewis92, thanks for this, I didn't know it even existed! I'll merge now and try to publish a beta version to verify :)

mattlewis92 commented 6 years ago

Ah, I've just found a bug on our test app, fix incoming!