How to auto generate docstring snippets for python modules in VsCode?

Viewed 4577

I have installed the Visual Studio Code extension Python Docstring Generator that autogenerates docstring snippet.

Customized settings that I use:

"autoDocstring.docstringFormat": "sphinx",
"autoDocstring.generateDocstringOnEnter": true,
"autoDocstring.includeExtendedSummary": true,
"autoDocstring.guessTypes": true,
"autoDocstring.customTemplatePath": ".vscode/sphinx.mustache",

However, it is mostly useful for function's docstring.

How can I also generate:

  • docstring for modules and scripts: entered in the beginning of the module
  • packages: Added to the __init__.py file
  • classes

Any idea in this regard?

0 Answers
Related