CodeMirror has content but won't display until keypress
问题 I have a CodeMirror instance embedded in a webapp I'm building. It works great - except that the initial content won't display until user enters a new character. So it is all there but hidden until the user forces a change. This is bad. Is there any way I can force a repaint or refresh of the browser of simulate a character enter - whitespace will do. Here is the code... <textarea id='code-mirror' ><?php echo $contents; ?></textarea> <script> jQuery(document).ready(function(){ var textarea =