.. _chapter2: Chapter 2: Including JavaScript =============================== Lets's use chapter to add some JavaScript code here: With ``.. code-block:: js`` we can add JavaScript snippets: .. code-block:: js function foo() { console.log('hello sphinx!') } Source Code Documentation ------------------------- .. js:autoclass:: Foo :members: :private-members: