Bug 1419772 - [docs] Enable the sphinx.ext.napoleon extension, r?gps draft
authorAndrew Halberstadt <ahalberstadt@mozilla.com>
Wed, 22 Nov 2017 10:17:12 -0500
changeset 702007 4ed82ca3f97ce1b00acd76a754b760c85c35c3a1
parent 701872 5378dcb45044a160fad93b02eed0c617f3324dbc
child 741331 ee3bb0577e947e5685266e91c7ceac2d12a62da4
push id90343
push userahalberstadt@mozilla.com
push dateWed, 22 Nov 2017 15:29:04 +0000
reviewersgps
bugs1419772
milestone59.0a1
Bug 1419772 - [docs] Enable the sphinx.ext.napoleon extension, r?gps This enables sphinx to parse both the google and numpy style docstring formats which tend to be more human readable than the default sphinx format. See: http://www.sphinx-doc.org/en/stable/ext/napoleon.html MozReview-Commit-ID: REmZ4IoUG8
tools/docs/conf.py
--- a/tools/docs/conf.py
+++ b/tools/docs/conf.py
@@ -31,16 +31,17 @@ EXTRA_PATHS = (
 
 sys.path[:0] = [os.path.join(topsrcdir, p) for p in EXTRA_PATHS]
 
 sys.path.insert(0, OUR_DIR)
 
 extensions = [
     'sphinx.ext.autodoc',
     'sphinx.ext.graphviz',
+    'sphinx.ext.napoleon',
     'sphinx.ext.todo',
     'mozbuild.sphinx',
     'sphinx_js',
 ]
 
 # JSDoc must run successfully for dirs specified, so running
 # tree-wide (the default) will not work currently.
 js_source_path = ['toolkit/mozapps/extensions']