All Projects → heavenshell → Vim Jsdoc

heavenshell / Vim Jsdoc

Licence: other
Generate JSDoc to your JavaScript code.

Labels

Projects that are alternatives of or similar to Vim Jsdoc

Esdoc
ESDoc - Good Documentation for JavaScript
Stars: ✭ 2,706 (+590.31%)
Mutual labels:  jsdoc
sveld
Generate TypeScript definitions for your Svelte components
Stars: ✭ 281 (-28.32%)
Mutual labels:  jsdoc
docgen
The docs.json generator for discord.js and its related projects
Stars: ✭ 59 (-84.95%)
Mutual labels:  jsdoc
examplejs
A tool for converting example code into test cases
Stars: ✭ 44 (-88.78%)
Mutual labels:  jsdoc
swagger-egg
Eggjs Swagger-UI API文档自动生成插件(如果喜欢请点赞支持)。Egg swagger documentation generator(welcome to star this project).
Stars: ✭ 31 (-92.09%)
Mutual labels:  jsdoc
tidy-jsdoc
A clean JSDoc3 template
Stars: ✭ 16 (-95.92%)
Mutual labels:  jsdoc
Type O Rama
👾 JS type systems interportability
Stars: ✭ 217 (-44.64%)
Mutual labels:  jsdoc
Compodoc
📔 The missing documentation tool for your Angular, Nest & Stencil application
Stars: ✭ 3,567 (+809.95%)
Mutual labels:  jsdoc
jsdoc-http-plugin
Document your http endpoints with JSDoc
Stars: ✭ 38 (-90.31%)
Mutual labels:  jsdoc
jsdast
JSDoc Abstract Syntax Tree
Stars: ✭ 20 (-94.9%)
Mutual labels:  jsdoc
jsdoc-action
📖 GitHub Action to build JSDoc documentation
Stars: ✭ 61 (-84.44%)
Mutual labels:  jsdoc
jsdoc-api
A programmatic interface for jsdoc3 with a few extra features
Stars: ✭ 55 (-85.97%)
Mutual labels:  jsdoc
ts-lehre
Generate document block(JsDoc, EsDoc, TsDoc) from source code
Stars: ✭ 14 (-96.43%)
Mutual labels:  jsdoc
hypatia
Convert JavaScript doctrings (in jsdoc AST format) to ijavascript Jupyter Notebooks
Stars: ✭ 12 (-96.94%)
Mutual labels:  jsdoc
Vscode Docthis
JSDoc generator extension for Visual Studio Code.
Stars: ✭ 284 (-27.55%)
Mutual labels:  jsdoc
Openapi Comment Parser
⚓️ JSDoc Comments for the OpenAPI Specification
Stars: ✭ 221 (-43.62%)
Mutual labels:  jsdoc
soulsign-scripts
📝 一部分是个人为魂签制作的签到脚本,还有一些个人使用的签到脚本。
Stars: ✭ 50 (-87.24%)
Mutual labels:  jsdoc
Tsdoc
A doc comment standard for TypeScript
Stars: ✭ 3,785 (+865.56%)
Mutual labels:  jsdoc
Docma
A powerful tool to easily generate beautiful HTML documentation from JavaScript (JSDoc), Markdown and HTML files.
Stars: ✭ 287 (-26.79%)
Mutual labels:  jsdoc
generator-vintage-frontend
Modern front-end workflow
Stars: ✭ 15 (-96.17%)
Mutual labels:  jsdoc

jsdoc.vim

build

jsdoc.vim generates JSDoc block comments based on a function signature.

jsdoc.vim

Note

jsdoc.vim supports Vim8.

Neovim works since v2.1.0, but if something wrong, send me pull requests to fix it.

If you want use old version checkout 1.0.0.

Install

Vim Plug

Plug 'heavenshell/vim-jsdoc', { 
  \ 'for': ['javascript', 'javascript.jsx','typescript'], 
  \ 'do': 'make install'
\}
PlugUpdate error

If you got `yarn.lock` related error,

error: Your local changes to the following files would be overwritten by merge:
    lib/yarn.lock

Run following command

cd /path/to/plugged/vim-jsdoc
git checkout -- yarn.lock

and re-run PlugUpdate

Manual Installation

Since version 2.0.0, jsdoc.vim requires a local copy lehre installed to the plugin directory.

You can install lehre with:

# cd to <vim-jsdoc path>
make install

If you want to update lehre use:

make clean
make install

If you want install lehre manually, you can install from npm.

$ yarn add -D lehre

Set installed /path/to/node_modules/.bin/lehre path to g:jsdoc_lehre_path.

Usage

  1. Move cursor on function keyword line
  2. Type :JsDoc to insert JSDoc
  3. Insert JSDoc above the function keyword line

Format

  1. Type :JsDocFormat
  2. Insert JSDoc above the all signatures

Configuration

Option Default Description
g:jsdoc_templates_path '' Path to custom template.
g:jsdoc_formatter 'jsdoc' Document block formatter, jsdoc, esdoc, tsdoc
g:jsdoc_lehre_path './lib/lehre' Path to lehre.

Formatter

You can choose formatter from JsDoc, ESDoc, TSDoc.

If you want to create your own template, see example template.

Intaractive input

Since ver 2.0.0 input Allow prompt for interactive input is deprecated.

If you want input Intaractively, use snippet plugin.

See snippet example template.

Keymap

You can add following setting to .vimrc

nmap <silent> <C-l> <Plug>(jsdoc)

Alternatively, you could add the following setting to your .vimrc to search for the last function declaration and puts your jsdoc above it:

nmap <silent> <C-l> ?function<cr>:noh<cr><Plug>(jsdoc)

Thanks

LICENSE

New BSD LICENSE

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].