Open kurucu opened 4 years ago
EasyMDE creates the HTML elements when the page loads, so that will probably confuse PurgeCSS. You could try adding all the classes in https://github.com/Ionaru/easy-markdown-editor/blob/master/src/css/easymde.css to the whitelist, but this can be tedious and isn't guaranteed to work with future updates.
Hi Ionaru.
Other libraries work the same way (creates elements when instantiated) but they only have one or two namespaces or patterns to put in the passlist. (e.g. Pikaday, which starts all classes with "pika-").
One way around it would be to add the following at the beginning and end of the EasyMDE css file:
/*! purgecss start ignore */
/*! purgecss end ignore */
Describe your question Are EasyMDE classes namespaced?
What do I (can I) whitelist with PurgeCSS to get it to overlook EasyMDE? As far as I can tell, this isn't a simple task - but perhaps I'm missing something.