npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

@stijn-dejongh/docsify-glossary

v1.0.1

Published

A simple glossary plugin for docsify, forked from the original work by TheGreenToaster

Downloads

20

Readme

docsify-glossary: SD Development Fork

Quality Gate Status

Simple Glossary for Docsify that replaces occurrences of words in text with links to the glossary definitions. Forked from TheGreenToaster/docsify-glossary as the original project was unmaintained for over 3 years, to address a couple of usability issues with the original script.

An example usage can be found here ./example, it is deployed automatically to this GitHub page.

Example of the glossary replacements

Installation

  1. Download the latest version of the javascript (from our releases page)
  2. Add the script into your docsify source directory
  3. Insert script into docsify.template.js document
<script src="./docsify-glossary.min.js"></script>
  1. Create a _glossary.md file in the root directory
  2. Populate the _glossary.md file with terms.

Plugin Usage

  • Terms must be predicated with a consistent Markdown heading to get recognized by the glossary (see configuration)
  • Terms are replaced with links in the order that they appear in the glossary file.
    • This is especially relevant for nested terminology ( e.g. API and API Usage)

Configuration

This version of the docsify-glossary plugin allows you to configure multiple aspects of the glossary. An example configuration is shown here:

glossify: {
    debug: false, # default
    glossaryLocation: './X_Appendix/Glossary/HOME.md', # default is '_glossary.md'
    terminologyHeading: '##', # default is '####', overwrite to fit your glossary heading depth
    replaceTitleTerms: false  # default is 'true'
}

Running the code

In order to run the code, you will need a node set-up on your local machine. We recommend using Node Version Manager to make this easier.

Building the code

  1. Globally install docsify: npm i docsify-cli -g
  2. From the project root directory, run: npm install
  3. To build the code, run: npm run ci
  4. THis will compile, test, and package the plugin

View the example website

Once the code has been built, you can launch the example website illustrating the use of the glossary. In order to do so:

  1. Go to http://localhost:3000/
  2. copy the latest version of the code into the example website: cp ./dist/@stijn-dejongh/docsify-glossary* ./example
  3. Run docsify serve example

Changelog

An overview of all the changes made to this codebase can be found in the CHANGELOG file included in this repository.

TODO list

  • [x] Bump dependency versions
  • [x] add unit tests to the code to make this package more maintainable