jlengstorf / learn-rollup

This is an example project to accompany a tutorial on using Rollup.
https://code.lengstorf.com/learn-rollup-js/
ISC License
191 stars 59 forks source link

Replace tip #3

Closed ghost closed 8 years ago

ghost commented 8 years ago

Dunno if this is the right place to this, but...

I have struggled with rollup-plugin-replace for half an hour about it being breaking stuff when I put react in my project when reading/watching https://code.lengstorf.com/learn-rollup-js/

The thing is that by default replace will transform node_modules modules too and in order to avoid it we have to add node_modules/** to the exclude option passed to replace.

You could put a tip in your article in order to help others not being trapped in this situation.

Ty 4 the awesome content.

jlengstorf commented 8 years ago

I added a note in jlengstorf/code.lengstorf.com@688e3d7567b0ecc228c05464a2bb0040dc7498b3.

Thanks for the heads-up!