diff options
author | Samy Pessé <samypesse@gmail.com> | 2016-02-17 13:59:52 +0100 |
---|---|---|
committer | Samy Pessé <samypesse@gmail.com> | 2016-02-17 13:59:52 +0100 |
commit | c0196c97a50786cd28c9b72197b39fefb47be333 (patch) | |
tree | 1798de09f97132777613aec6c5f3714d56417bd3 /docs | |
parent | 96105d6ba0ac1bc86bd34088ae4763bf09b3c3ea (diff) | |
download | gitbook-c0196c97a50786cd28c9b72197b39fefb47be333.zip gitbook-c0196c97a50786cd28c9b72197b39fefb47be333.tar.gz gitbook-c0196c97a50786cd28c9b72197b39fefb47be333.tar.bz2 |
Add context for summary
Diffstat (limited to 'docs')
-rw-r--r-- | docs/variables.md | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/docs/variables.md b/docs/variables.md index a0fc64e..bf2e88d 100644 --- a/docs/variables.md +++ b/docs/variables.md @@ -10,6 +10,7 @@ The following is a reference of the available data during book's parsing and the | `gitbook` | GitBook specific information | | `page` | Current page specific information | | `file` | File associated with the current page specific information | +| `summary` | Information about the table of contents | ### Book Variables @@ -41,6 +42,13 @@ The following is a reference of the available data during book's parsing and the | `page.previous` | Previous page in the Table of Contents (can be `null`) | | `page.next` | Next page in the Table of Contents (can be `null`) | +#### Table of Contents Variables +| Variable | Description | +| -------- | ----------- | +| `summary.parts` | List of sections in the Table of Contents | + +Thw whole table of contents (`SUMMARY.md`) can be accessed: +`summary.parts[0].articles[0].title` will return the title of the first article. |