nestjs / serve-static

Serve static websites (SPA's) using Nest framework (node.js) šŸ„¦

Home Page:https://nestjs.com/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

fastify-static is deprecated use @fastify/static instead

SteadEXE opened this issue Ā· comments

Is there an existing issue for this?

  • I have searched the existing issues

Current behavior

A deprecated warning get triggered when we use "@nestjs/serve-static": "2.2.2"

Minimum reproduction code

https://gist.github.com/SteadEXE/2220524c25cbd59ab04ce5d772d7b56e

Steps to reproduce

  1. Create a nestjs project
  2. Add Fastify and @nestjs/serve-static
  3. Run the application.

Expected behavior

No warning in the console

Package version

2.2.2

NestJS version

8.4.5

Node.js version

16.15.0

In which operating systems have you tested?

  • macOS
  • Windows
  • Linux

Other

(node:13584) [FST_MODULE_DEP_FASTIFY-STATIC] FastifyWarning.fastify-static: fastify-static has been deprecated. Use @fastify/static@5.0.0 instead.
(Use node --trace-warnings ... to show where the warning was created)