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

gitbook-plugin-comments-footer

v1.6.0

Published

A repo focusing on comments integrated with code management providers like GitLab or GitHub.

Downloads

76

Readme

gitbook-comments

A project focusing on comments integrated with code management providers like GitLab or GitHub.

npm javascript gitbook gitbook

GitHub license npm

comments-footer

Installation

Add the following plugins to your book.json and run the command gitbook install

{
	"plugins": ["comments-footer"]
}

Usage

1. GitHub

To use this plugin in a GitBook project deployed on GitHub, the first step is to install the GitHub app in your repository for accessing.

And then, the configuration option can be set as an object like the following snippet:

{
	"plugins": [
		"comments-footer"
	],
	"pluginsConfig": {
		"comments-footer": {
			"type": "github",
			"repo": "aleen42/PersonalWiki",
			"copyright": "Copyright © aleen42"
		}
	}
}

2. GitLab

What if using it in GitLab? You may need to create an application yourself with API scope accessing.

gitbook-comments

  • Name: any name you want
  • Redirect URI: the page url you published
  • Scopes: choose api

And then, the configuration option can be set as an object like the following snippet:

{
	"plugins": [
		"comments-footer"
	],
	"pluginsConfig": {
		"comments-footer": {
			"type": "gitlab",
			"repo": "fe-components/fe-documents",
			"copyright": "Copyright © aleen42",
			"redirect": "xxx",
			"clientId": "xxx",
			"host": "http://git.xxx.cn/"
		}
	}
}
  • redirect: the page url you published
  • clientId: the Application ID of your application created above
  • host: the GitLab server host

TODO

  • [ ] Disable subscribing states when commenting on articles.
  • [x] ~~Heroku is UNSTABLE for GitHub authorization!~~ Migrated to deta.space
  • [x] Replying features on GitLab.
  • [x] ~~GitLab features depend on the functions around commit comments: https://gitlab.com/gitlab-org/gitlab-ce/issues/59798.~~ Use discussion instead.
  • [x] ~~GitLab private access token has no detailed scope for avoiding abusing by others.~~ It means that I cannot get discussions when users do not authorize themselves.

Release History

  • ==================== 1.0.0 Initial release ====================
    • 1.1.2 oauth2 integration
    • 1.1.3 initial structure for featuring GitHub
    • 1.1.4 fix bug
    • 1.1.5 enhancement for reducing authorizing redirecting
    • 1.1.6 enhancement of compatible styles
    • 1.1.9 styles for the authorization wrapper and unexpected redirect url
    • 1.2.0 support GitLab
    • 1.2.2 fix commented time and passed parameters when leaving comments in GitLab
    • 1.2.3 show user link anchor
    • 1.2.5 bug fix and show site link after leaving comments
    • 1.2.7 list all commits recursively
    • 1.2.9 bug fix
    • 1.3.0 more restrict regression for matching commit difference
    • 1.3.1 support replying features in GitLab
    • 1.3.2 redirect to visited site after authorized in GitLab
    • 1.3.3 fix NPE problem
    • 1.3.5 autocomplete feature within GitLab and fix a bug
    • 1.3.7 unified font sizes
    • 1.3.8 compatible autocomplete for GitHub
    • 1.3.9 feature autocomplete for GitHub
    • 1.4.2 deprecated token access way for GitHub
    • 1.4.3 keep token in url queries for GitLab
    • 1.4.5 audit vulnerable dependencies
    • 1.4.7 avoid downloading font-awesome via using SimpleMDE
    • 1.4.9 avoid exposing token via Heroku
    • 1.5.2 use gitbook-color to support light or dark theme
    • 1.5.7 fix some problems
      • avoid empty token
      • fix wrong z-index of book header
      • base64 encode token to avoid detection of GitHub
    • 1.6.0 migrate the server from Heroku to deta.space

Q&A

  1. Why does requests towards GitLab API fails the policy of CORS? #4

    I have tested under CE 11.7.5 and GitLab has already set Access-Control-Allow-Origin: * for all requests of api/* under a GET way by default. If not for your environment, try to find a way to configure it.

:fuelpump: How to contribute

Have an idea? Found a bug? See how to contribute.

:scroll: License

MIT © aleen42

Note: if you like this project, feel free to buy me a swimming chance:

badges badges badges