Adding runmode for codemirror