Closed rolznz closed 1 year ago
Thank you for pointing this out @rolznz! This change was made intentionally so that users who don't want to use this render import don't need to install its dependencies, but we hadn't updated to reflect this in the READEME. This PR should address it: https://github.com/Faire/mjml-react/pull/65
@emmclaughlin I looked at the PR. Isn't there another way you can expose the import without having to import from the dist directory? this seems wrong to me.
We need to keep the render function out of the main index.ts file in order to fix dependency issues (e.g. https://github.com/Faire/mjml-react/issues/36). That said, agree it feels odd with the dist directory, will see if we can clean that up
If anyone has ideas of how to make this better for both esm
and cjs
we'd love to get help with this.
I think we can close this ticket and explore exporting to both esm
and cjs
in #72
Unlike the example in the README, I have to import directly from the source:
from maintainers
Ideally the goal would be:
Two blockers: