Skip to content

Commit 8b5481c

Browse files
committed
Use uvu
1 parent 8c572df commit 8b5481c

File tree

4 files changed

+568
-3034
lines changed

4 files changed

+568
-3034
lines changed

package.json

+7-15
Original file line numberDiff line numberDiff line change
@@ -97,36 +97,32 @@
9797
"@babel/core": "^7.0.0",
9898
"@babel/preset-env": "^7.0.0",
9999
"@babel/preset-react": "^7.0.0",
100-
"@matejmazur/react-katex": "^3.0.0",
101-
"@testing-library/react": "^12.0.0",
102-
"@types/jest": "^26.0.0",
103100
"@types/react": "^17.0.0",
104101
"@types/react-dom": "^17.0.0",
105102
"@types/react-is": "^17.0.0",
106-
"@types/react-test-renderer": "^17.0.0",
107103
"babel-plugin-transform-react-remove-prop-types": "^0.4.24",
104+
"c8": "^7.8.0",
108105
"esbuild": "^0.12.0",
106+
"esbuild-register": "^2.6.0",
109107
"eslint-config-xo-react": "^0.25.0",
110108
"eslint-plugin-es": "^4.0.0",
111109
"eslint-plugin-react": "^7.0.0",
112110
"eslint-plugin-react-hooks": "^4.0.0",
113111
"eslint-plugin-security": "^1.0.0",
114-
"jest": "^27.0.0",
115112
"katex": "^0.13.0",
116113
"npm-run-all": "^4.0.0",
117114
"prettier": "^2.0.0",
118115
"react": "^17.0.0",
119116
"react-dom": "^17.0.0",
120-
"react-test-renderer": "^17.0.0",
121117
"rehype-raw": "^5.0.0",
122118
"remark-cli": "^9.0.0",
123119
"remark-gfm": "^1.0.0",
124-
"remark-math": "^4.0.0",
125120
"remark-preset-wooorm": "^8.0.0",
126121
"remark-toc": "^7.0.0",
127122
"rimraf": "^3.0.0",
128123
"type-coverage": "^2.0.0",
129124
"typescript": "^4.0.0",
125+
"uvu": "^0.5.1",
130126
"xo": "^0.38.0"
131127
},
132128
"scripts": {
@@ -135,8 +131,9 @@
135131
"build:umd": "esbuild src/react-markdown.js --bundle --minify --target=es2015 --outfile=react-markdown.min.js --global-name=ReactMarkdown --banner:js=\"(function (g, f) {typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = f() : typeof define === 'function' && define.amd ? define([], f) : (g = typeof globalThis !== 'undefined' ? globalThis : g || self, g.ReactMarkdown = f()); }(this, (function () { 'use strict';\" --footer:js=\"return ReactMarkdown;})));\"",
136132
"build": "run-s build:*",
137133
"format": "remark . -qfo --ignore-pattern test/ && prettier . -w --loglevel warn && xo --fix",
138-
"test": "run-s build format test:*",
139-
"test:unit": "jest --coverage"
134+
"test": "run-s build format test:coverage",
135+
"test:unit": "uvu -r esbuild-register test",
136+
"test:coverage": "c8 --check-coverage --branches 100 --functions 100 --lines 100 --statements 100 --reporter lcov npm run test:unit"
140137
},
141138
"browserslist": "> 0.25%, not dead",
142139
"remarkConfig": {
@@ -212,16 +209,11 @@
212209
}
213210
},
214211
{
215-
"envs": [
216-
"jest"
217-
],
218212
"files": [
219-
"test/**/*.js"
213+
"test/**/*.jsx"
220214
],
221215
"rules": {
222216
"react/no-children-prop": 0,
223-
"react/display-name": 0,
224-
"no-nested-ternary": 0,
225217
"react/prop-types": 0
226218
}
227219
}

0 commit comments

Comments
 (0)