IonicaBizau/medium-editor-markdown

Internet explorer support

vclayton opened this issue · 1 comments

Sadly, our application requires us to support at least some version of IE. Medium Editor itself does, but this extension does not.

Problem 1: String.prototype.trimRight is a non-standard function, and is not implemented in any version of IE. It's used in the init handler function, which could use a regex instead.

Problem 2: A number of places that expect DOM nodes are sometimes passed undefined. I have a naive solution in all the places that I've seen it crash, that checks for this and substitutes a dummy object.

Will send a PR for review or better ideas.

After digging further, it seems that problem 2 is actually in the to-markdown code. I'll investigate further there.

String.prototype.trimRight is a non-standard function

Oh, thanks for that! I didn't know it.

Will take a look at the PR.