Skip to content

Generate a table of contents for your posts based on headings

License

Notifications You must be signed in to change notification settings

kickthemooon/simple-contents

Repository files navigation

Simple Contents

Generate a contents block based on headings in your post / article.

Example

Installation

NPM

npm install simple-contents

Browser

<script src="https://cdn.jsdelivr.net/npm/simple-contents@latest/index.umd.js"></script>

Usage

Module

import simpleContents from 'simple-contents';
simpleContents.init('sourceSelector', 'targetSelector');

Browser

SimpleContents.init('sourceSelector', 'targetSelector');

About

Generate a table of contents for your posts based on headings

Topics

Resources

License

Stars

Watchers

Forks