I have a react application that uses the unlayer email editor. I also have some custom tools which I include in the editor like this:
import EmailEditor from 'react-email-editor';
<EmailEditor projectId={1071} options={{customJS: ['https://cdn.jsdelivr.net/gh/maxt41/unlayer-tools@d874675d04fcf4942f7eef264119af8afc362f1d/LinkCaptureTool.js', 'https://cdn.jsdelivr.net/gh/maxt41/unlayer-tools@d874675d04fcf4942f7eef264119af8afc362f1d/UnsubscribeTool.js']}} ref={emailEditorRef} />
That line alone generates the entire email editor and the customJS: ...
references my custom tools.
This is the Email editor in React development mode:
This is the Email editor in React build mode:
Obviously the custom tools are "hosted" elsewhere so I am unsure why when building the app they aren't showing. I have tried making them within the app but I can't figure out how to reference them as customJS tools and I'm unsure if that would fix the issue.
I have tried rebuilding and recreating the Jsdelivr links to no avail. The tools themselves also work perfectly in development. There is no error messages in console or with react dev tools.