Closed somini closed 6 years ago
Updated to the latest version.
The plugin fits into one 4k disk sector. What could possibly be the value in autoloading it?!
What could possibly be the value in autoloading it?!
At least in my case, I consider it a good approach to only loading anything until it is really needed.
Another plus is "forcing" defining a clear separation between internal functions and an exposed API.
The counterpoint is that a single file plugin is significantly easier for ad hoc installations, like if you want to dump it on a random server, for example. It's a small thing, but it does win out over minor code organization concerns.
Furthermore, all functions in Commentary are internal, but autoloading requires me to expose them as an implementation detail. It doesn't force a clear separation, it prevents it. In dispatch.vim, for example, the official API is :Make
(so you can swap in :make
if it's not available, and avoid a hard dependency), but people are sometimes distracted by internal APIs that are necessarily exposed. The namespacing is great for when you do want to expose functions, but I have no reason to do that here.
Similar to #78, to the latest master.