diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 6890770..a9aabfb 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -18,6 +18,16 @@ jobs: - run: npm run type-check - run: npm run coverage + - run: npm i coverage-badges-cli -g + - run: coverage-badges + - run: npm run doc + + - name: Deploy + uses: peaceiris/actions-gh-pages@v3 + with: + github_token: ${{ secrets.GITHUB_TOKEN }} + publish_dir: ./coverage + - run: npm install @jsdevtools/npm-publish -g - run: npm-publish --token="${{ secrets.NPM_TOKEN }}" ./package.json @@ -54,8 +64,3 @@ jobs: ${{ steps.changelog.outputs.compareurl }} ${{ steps.changelog.outputs.changelog }} - - - name: Coveralls - uses: coverallsapp/github-action@master - with: - github-token: ${{ secrets.GITHUB_TOKEN }} \ No newline at end of file diff --git a/README.md b/README.md index 64c8e54..40bdece 100644 --- a/README.md +++ b/README.md @@ -5,7 +5,7 @@ rehype-attr [![Downloads](https://img.shields.io/npm/dm/rehype-attr.svg?style=flat)](https://www.npmjs.com/package/rehype-attr) [![NPM version](https://img.shields.io/npm/v/rehype-attr.svg?style=flat)](https://npmjs.org/package/rehype-attr) [![Build](https://github.com/jaywcjlove/rehype-attr/actions/workflows/ci.yml/badge.svg)](https://github.com/jaywcjlove/rehype-attr/actions/workflows/ci.yml) -[![Coverage Status](https://coveralls.io/repos/github/jaywcjlove/rehype-attr/badge.svg?branch=main)](https://coveralls.io/github/jaywcjlove/rehype-attr?branch=main) +[![Coverage Status](https://jaywcjlove.github.io/rehype-attr/badges.svg)](https://jaywcjlove.github.io/rehype-attr/lcov-report) [![npm bundle size](https://img.shields.io/bundlephobia/minzip/rehype-attr)](https://bundlephobia.com/result?p=rehype-attr) New syntax to add attributes to Markdown. `rehype-attr` like [`remark-attr`](https://github.com/arobase-che/remark-attr) diff --git a/package.json b/package.json index 92ddc63..d925797 100644 --- a/package.json +++ b/package.json @@ -39,6 +39,10 @@ "testMatch": [ "/test/*.{ts,tsx}" ], + "coverageReporters": [ + "lcov", + "json-summary" + ], "collectCoverageFrom": [ "/src/*.{tsx,ts}" ],