CodeMirror Keymap: Vim plugin seems to be causing an error

187 views
Skip to first unread message

TJ Walker

unread,
Jun 26, 2018, 4:33:19 PM6/26/18
to TiddlyWiki
I just added to my TW (5.1.17) wiki the main CM plugin along with the vim keymap plugin for it. It's not working.

index.html:11067 Error executing boot module $:/plugins/tiddlywiki/codemirror/keymap/vim.js: "Cannot find module named '../addon/edit/matchbrackets.js' required by module '$:/plugins/tiddlywiki/codemirror/keymap/vim.js', resolved to $:/plugins/tiddlywiki/codemirror/addon/edit/matchbrackets.js"

undefined
$tw.utils.error @ index.html:11067
$tw.modules.execute @ index.html:11691
require @ index.html:11614
(anonymous) @ $:/plugins/tiddlywiki/codemirror/engine.js:31
(anonymous) @ $:/plugins/tiddlywiki/codemirror/engine.js:208
(anonymous) @ $:/plugins/tiddlywiki/codemirror/engine.js:210
$tw.utils.evalGlobal @ index.html:11383
$tw.modules.execute @ index.html:11667
require @ index.html:11614
(anonymous) @ $:/plugins/tiddlywiki/codemirror/edit-codemirror.js:17
(anonymous) @ $:/plugins/tiddlywiki/codemirror/edit-codemirror.js:21
(anonymous) @ $:/plugins/tiddlywiki/codemirror/edit-codemirror.js:23
$tw.utils.evalGlobal @ index.html:11383
$tw.modules.execute @ index.html:11667
(anonymous) @ index.html:11707
$tw.utils.each @ index.html:11013
$tw.modules.forEachModuleOfType @ index.html:11706
$tw.modules.applyMethods @ index.html:11730
Widget.initialise @ $:/core/modules/widgets/widget.js:50
Widget @ $:/core/modules/widgets/widget.js:27
exports.startup @ $:/core/modules/startup.js:92
$tw.boot.executeNextStartupTask @ index.html:13040
$tw.boot.executeNextStartupTask @ index.html:13044
$tw.boot.executeNextStartupTask @ index.html:13044
$tw.boot.startup @ index.html:12997
(anonymous) @ index.html:13150
$tw.boot.decryptEncryptedTiddlers @ index.html:12337
$tw.boot.boot @ index.html:13148
_boot @ index.html:13157
(anonymous) @ index.html:13167
$:/core/modules/utils/logger.js:33  performance: mainRender: 203.06ms
$:/core/modules/utils/logger.js:33  performance: +filter: 12.94ms
$:/core/modules/utils/logger.js:33  performance: styleRefresh: 8.22ms
$:/core/modules/utils/logger.js:33  performance: +filter: 1.13ms
$:/core/modules/utils/logger.js:33  performance: mainRefresh: 40.80ms
$:/core/modules/utils/logger.js:33  performance: +filter: 12.64ms
$:/core/modules/utils/logger.js:33  performance: styleRefresh: 10.03ms
$:/core/modules/utils/logger.js:33  performance: +filter: 3.50ms
$:/core/modules/utils/logger.js:33  performance: mainRefresh: 32.01ms
$:/core/modules/utils/logger.js:33  performance: +filter: 9.50ms
$:/core/modules/utils/logger.js:33  performance: styleRefresh: 9.14ms
$:/core/modules/utils/logger.js:33  performance: +filter: 3.08ms

Any thoughts?

talha131

unread,
Jul 7, 2018, 3:18:18 PM7/7/18
to TiddlyWiki

I also failed to make Vim plugin work. From CodeMirror official site

Note: The CodeMirror vim bindings do not have an active maintainer. That means that if you report bugs in it, they are likely to go unanswered. It also means that if you want to help, you are very welcome to look at the open issues and see which ones you can solve.

But still, it could be an error in TiddlyWiki. Nonetheless, for the time being, I have switched to Wasavi addon on to get Vim inside TiddlyWiki editor.

PMario

unread,
Jul 8, 2018, 4:15:32 AM7/8/18
to tiddl...@googlegroups.com
On Tuesday, June 26, 2018 at 10:33:19 PM UTC+2, TJ Walker wrote:
I just added to my TW (5.1.17) wiki the main CM plugin along with the vim keymap plugin for it. It's not working.

index.html:11067 Error executing boot module $:/plugins/tiddlywiki/codemirror/keymap/vim.js: "Cannot find module named '../addon/edit/matchbrackets.js' required by module '$:/plugins/tiddlywiki/codemirror/keymap/vim.js', resolved to $:/plugins/tiddlywiki/codemirror/addon/edit/matchbrackets.js"

The "big" modes, like vim, emacs and sublime basically __need__ any other plugin, that is available.

Have a closer look at the control panel: https://tiddlywiki.com/plugins/tiddlywiki/codemirror/  and see what's needed for sublime. ... vim and emacs have the same dependencies.

We should probalby create some bundles, which would make it possible to install several plugins in 1 go.

have fun!
mario

talha131

unread,
Mar 26, 2019, 4:12:37 AM3/26/19
to TiddlyWiki

I gave a try to codemirror and its Vim keymap again. It turned out then I need all following plugins to make codemirror work with Vim keymaps

        "tiddlywiki/codemirror",
        "tiddlywiki/codemirror-closebrackets",
        "tiddlywiki/codemirror-keymap-vim",
        "tiddlywiki/codemirror-search-replace",

Hope someone else will find it useful.

Reply all
Reply to author
Forward
0 new messages