A relative link is a link that points to a resource that will be present a final URL relative to the input .bigb file.
For example, it is often the case in computer programming tutorials that we want to refer to source files in the current directory.
So from our README.bigb, we could want to write something like:
Have a look at this amazing source file: \a[index.js].
which renders as:
Have a look at this amazing source file: index.js.
and here \a[ourbigbook] is a relative link.
A non-relative link is something like:
This is great website: https://cirosantilli.com
which renders as:
This is great website: cirosantilli.com
which points to an absolute URL.
A link being relative has the following effects
  • the correct relative path to the file is used when using nested scopes with -S, --split-headers. For example, if we have:
    = h1
    
    == h2
    {scope}
    
    === h3
    
    \a[index.js]
    then in split header mode, h3 will be rendered to h2/h3.html.
    Therefore, if we didn't do anything about it, the link to index.js would render as href="index.js" and thus point to h2/index.js instead of the correct index.js.
    Instead, OurBigBook automatically converts it to the correct href="../index.js"
OurBigBook considers a link relative by default if:
Therefore, the following are not relative links by default:
  • http://cirosantilli.com
  • https://cirosantilli.com
  • file:///etc/fstab
  • ftp://cirosantilli.com
  • /path/to/index.js
  • //example.com/path/to/index.js
and the following are:
  • index.js
  • ../index.js
  • path/to/index.js

Ancestors