[IPython-dev] CodeMirror Vim keymaps (ipython-notebook 3.1)

David Froger david.froger.ml at mailoo.org
Fri Apr 24 07:11:58 EDT 2015


Hi,

I'm trying to configure ipython-notebook 3.1 (installed with miniconda) to use
CodeMirror Vim keymaps.

I put in my ~/.ipython/profile_default/static/custom/custom.js:

    require(['base/js/namespace', 'base/js/events'], function(IPython, events) {
      events.on('app_initialized.NotebookApp', function() {
        $.getScript('/static/components/codemirror/keymap/vim.js');
        IPython.CodeCell.options_default.cm_config["keyMap"] = "vim"
      });
    });

But I got the error when openening a notebook:

    TypeError: next is undefined (codemirror.js:4622)

What is the correct way to get CodeMirror Vim Keymaps in ipython-notebook 3.1?

Thanks,
David




More information about the IPython-dev mailing list