Skip to content

Commit

Permalink
chore: name middleware
Browse files Browse the repository at this point in the history
  • Loading branch information
hi-ogawa committed Jan 22, 2025
1 parent 983b462 commit 3604f2e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion packages/ui/node/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,8 @@ export default (ctx: Vitest): Plugin => {
const clientIndexHtml = fs.readFileSync(resolve(clientDist, 'index.html'), 'utf-8')

// serve index.html with api token
server.middlewares.use((req, res, next) => {
// eslint-disable-next-line prefer-arrow-callback
server.middlewares.use(function vitestUiHtmlMiddleware(req, res, next) {
if (req.url) {
const url = new URL(req.url, 'http://localhost')
if (url.pathname === base) {
Expand Down

0 comments on commit 3604f2e

Please sign in to comment.