I just upgraded from version 1.10.1 to 1.11.0, and the exact same setup I had before now throws the error...
CodeMirror is not defined
anywhere that SimpleMDE tries to use CodeMirror. Reverting back to 1.10.1 resolves the problem. I'm really not sure where the error could be; my gulpfile just copies node_modules/simplemde/dist/simplemde.min.js to the requisite scripts directory in my application. It's worked great up until 1.11.0.
I can't reproduce this. Can you replicate it using JSFiddle?
I'll try. Though I might be more specific; It fails with SystemJS module loader, while 1.10.1 worked fine with it.
If I copy over the files directly from github, it works - but using the ones from npm does not work. I do not know how, but it appears they aren't the same.
Interestingly enough, there appears to be sizable differences between what NPM has and what GitHub has. GitHub's code is correct. I'll see what I can do.
Should be fixed now in 1.11.1. Let me know if not.
The issue seems to be present still :(
@WesCossick not sure if https://github.com/NextStepWebs/codemirror-spell-checker was published to NPM correctly. The source doesn't seem to reflect what's on git?
@WesCossick - fiddle here to demonstrate a simple installation failing with the "CodeMirror is not defined" console error: https://jsfiddle.net/o80upuzL/
A temporary workaround in my package.json I've referenced this:
"codemirror-spell-checker": "[email protected]:NextStepWebs/codemirror-spell-checker.git#e2c7e3b67438cf1202f1081d55d2a3f71f2779ff"
@WesCossick - your website is an example as well: https://simplemde.com/
Neither the JSFiddle nor the demo website exhibit the issue you've suggested. Potentially it's a browser or OS specific issue. What browser and OS are y'all using?
@WesCossick you're right. It's failing in Firefox Developer Edition, but working in Chrome (OSX)
For me it was failing on Chrome (OSX). But it felt like the package installed locally had a pretty old version of the code on the spell checker, hence me referencing a commit SHA instead.
It's failing on Chrome (OSX) now for me too.
Can identify where in the code this error first appears? I still cannot replicate it.
Uncaught ReferenceError: CodeMirror is not defined (simplemde.min.js:7)
Uncaught ReferenceError: SimpleMDE is not defined (my page)
CM trace:
r.4.typo-js @ simplemde.min.js:7
i @ simplemde.min.js:7
(anonymous function) @ simplemde.min.js:7
r.20../codemirror/tablist @ simplemde.min.js:14
i @ simplemde.min.js:7
t @ simplemde.min.js:7
(anonymous function) @ simplemde.min.js:7
(anonymous function) @ simplemde.min.js:7
(anonymous function) @ simplemde.min.js:7
Could you provide that same info, but using the debug version? Here's a CDN version: https://cdn.rawgit.com/NextStepWebs/simplemde-markdown-editor/master/debug/simplemde.debug.js
Sure:
spell-checker.js:25 Uncaught ReferenceError: CodeMirror is not defined
4.typo-js @ spell-checker.js:25
s @ b64.js:6
(anonymous function) @ b64.js:620
../codemirror/tablist @ simplemde.js:19
s @ b64.js:6
e @ b64.js:6
(anonymous function) @ b64.js:6
(anonymous function) @ b64.js:6
(anonymous function) @ b64.js:6
If I include CodeMirror before SimpleMDE, it works again provided I disable spell checking when instantiating the editor. If I don't disable it I get TypeError: CodeMirrorSpellChecker is not a function. Broken dependency loading?
Got the same issue. It's also showing on https://simplemde.com/.
Note that I did NOT upgrade. So I'm guessing the plugin is loading some assets that have changed or something.

No matter what browser and OS combination I use, I cannot replicate this issue. If someone who is able to can identify the problem, fix it, and submit a PR, that would be tremendously helpful.
@justusburger, what browser and OS versions are you using?
For reference, I'm primarily using Chrome 51.0.2704.84 m (64-bit) on Windows 10.
@WesCossick I'm also on 51.0.2704.84 (64-bit), but on OSX.
I'll have a look when I have a moment.
+1 here. Using the master branch directly.
Just for info, I get no such issue on simplemde.com using Windows 7, Chrome 64-bit 51.0.2704.84 m, nor on the same Chrome version in a Mac OSX VM. @justusburger Are you still seeing this error there?
Same issue here:
spell-checker.js:25Uncaught ReferenceError: CodeMirror is not defined4.typo-js
@ spell-checker.js:25s
@ b64.js:6(anonymous function)
@ b64.js:620../codemirror/tablist
@ simplemde.js:19s
@ b64.js:6e
@ b64.js:6(anonymous function)
@ b64.js:6(anonymous function)
@ b64.js:6(anonymous function)
@ b64.js:6
2:191 Uncaught ReferenceError: SimpleMDE is not defined
OS X, Chrome latest version
I've just got the same issue with:
The issue occurred only for version 1.11.1 of simplemde. Downgrading to 1.11.0 solved the problem.
@WesCossick If I let you teamviewer into my Mac to debug yourself, would that help?
Getting it here as well. It seems to happen on and off. 1.11.1.
I face the same issue. It was working perfectly and suddenly I got this error.
I am using the cdn version.
v1.11.0 works fine.
The following fiddle reproduces the bug using the raw debug of v1.1.11:
https://jsfiddle.net/alfhen/vofs9Lqz/10/
The bug occurs in both Safari and Chrome.
I think I found the issue. It looks like CodeMirror Spell Checker is using an older version of the code. Possibly the project was not built correctly or was not published to NPM correctly. I'm fixing this now...
Should be fixed now!
Issue still persist SimpleMDE is not defined.
jsDelivr works fine though
Most helpful comment
Should be fixed now!