The following is a guest post from Christopher Folger, creator of a Dojo plugin for the popular WebStorm IDE from JetBrains. Thanks Christopher for sharing information about your plugin.
Needs More Dojo is a plugin that provides awareness of Dojo’s AMD system and object model to the IDE. Its main purpose is to simplify the management of the imported modules array (and corresponding function parameters) in a define block.
For example, instead of typing “dijit/layout/ContentPane” and adding a “ContentPane” parameter, Needs More Dojo lets you type “ContentPane” then inserts the correct module path and parameter for you into the existing list of imports. As you are writing code, when you reference an AMD module, you can use a hot-key to import the module instead of adding it manually. It will also flag unused modules with a strike-through and allows you to remove all unused modules at once.
Apart from this, it has several other features:
- Allows you to organize, remove duplicates, or move items in a module’s list of imports via hot-keys or menu items
- Highlights mismatches between an imported module and its parameter
- Scans your sources and updates module references in define blocks when using the move/rename refactoring actions
- Detects and optionally highlights cyclic dependencies
- Allows navigation to attach points in modules that use _TemplatedWidget and i18n resource keys when using dojo/i18n!
- The upcoming release provides support for require blocks in addition to better navigation to modules, methods, and this.inherited references
It is open-source and is currently under development. Any feedback or feature requests are always welcome and can be made on GitHub