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

jest-md-dashboard

v0.8.0

Published

Generating a pretty Markdown dashboard for Jest

Downloads

719

Readme

jest-md-dashboard

npm version codecov test lint License: MIT

Generating a pretty Markdown dashboard for Jest

Table of Contents

Example

See https://github.com/tasshi-me/jest-md-dashboard/issues/20

Installation

npm

npm install -D jest-md-dashboard

yarn

yarn add -D jest-md-dashboard

pnpm

pnpm add -D jest-md-dashboard

Usage

Add reporters field in jest.config.js.

const config = {
  reporters: ["default", "jest-md-dashboard"],
};
module.exports = config;

Run jest and the dashboard is generated to test-dashboard.md.

With options

const config = {
  reporters: ["default", ["jest-md-dashboard", { title: "My Dashboard" }]],
};
module.exports = config;

Options

| Name | Type | Default | Description | | ------------------ | -------- | ------------------- | ------------------------------------------------------------------------------------------- | | title | string | "Test Dashboard" | The title of a dashboard.It will be printed at the top of the markdown output. | | outputPath | string | test-dashboard.md | The file path to output dashboard.If you want to output to stdout, specify -. | | permalinkBaseUrl | string | undefined | Override baseUrl of permalink.See Permalink section for more information. |

Permalink

jest-md-dashboard generates permalink to test files on GitHub (or other services) by default.

It tries to find git information from the following sources.

  1. permalinkBaseUrl option
  2. (on GitHub Actions) environment variables
  3. (in git repository) repository config

1. permalinkBaseUrl option

If permalinkBaseUrl is specified on jest config, jest-md-dashboard generates permalink using it.

Specify this option when if generated permalinks are incorrect.

The URL must have a trailing slash.

e.g. https://github.com/tasshi-me/jest-md-dashboard/blob/

2. Run on GitHub Actions

If jest runs on GitHub Actions, jest-md-dashboard refers to the the environment variables.

3. Run in git repository

If jest runs in a git repository, jest-md-dashboard refers to the local repository config.

Contribution

We appreciate your help!

License