A drop-in tool to show the current page position with regards to the table of content on an HTML page.
It creates a clickable navbar that dynamically displays the current <h[1-6]>
-tags tree branch. It has been created to keep track of the current position in the table of contents inside long markdown files, but can be used in other HTML pages as well.
Simply include brancher.js
inside your markdown or HTML page.
.md
<script src="../src/brancher.js" type="text/javascript"></script>
# Title
Some content
## Subtitle
...
.html
<!DOCTYPE html>
<html>
<head>
<title>Demo</title>
<!-- Include brancher.js -->
<script src="../src/brancher.js" type="text/javascript"></script>
</head>
<body>
...
brancher.js
copies all the body content and place it in a scrollable <div>
. The new body contains brancher container and the body-content container.
This approach may cause issues with the behavior of the page.
For the commit linter you need to install:
- commitlint
npm install --global @commitlint/cli @commitlint/config-conventional
- husky
npm install --global husky
npx husky install
- commitizen (cz)
npm install --global commitizen @commitlint/cz-commitlint
For commit linter, commit as usual, and the linter will run via git hooks.
To generate a good commit message use:
npx cz