diff --git a/en/guide/migrating-5.md b/en/guide/migrating-5.md index 4541a282c9..e79a827b04 100755 --- a/en/guide/migrating-5.md +++ b/en/guide/migrating-5.md @@ -56,8 +56,10 @@ You can find the list of available codemods [here](https://codemod.link/express)
  • res.send(body, status)
  • res.send(status)
  • res.sendfile()
  • +
  • res.sendFile() and express.static() options
  • router.param(fn)
  • express.static.mime
  • +
  • Removed send methods
  • express:router debug logs
  • @@ -402,6 +404,22 @@ const mime = require('mime-types') mime.lookup('json') ``` +

    res.sendFile() and express.static() options

    + +The following options to the `res.sendFile()` and `express.static()` functions are no longer supported: + +* `hidden`: Use the `dotfiles` option instead. +* `from`: Use the `root` option instead. + +

    Removed send methods

    + +The `send` package no longer exports the following methods. If your app relies on them, replace them with properties in the `options` object for `res.sendFile()` and `express.static()`: + +* `send.etag()`: Use the `etag` option instead. +* `send.index()`: Use the `index` option instead. +* `send.maxage()`: Use the `maxAge` option instead. +* `send.root()`: Use the `root` option instead. +

    express:router debug logs

    In Express 5, router handling logic is performed by a dependency. Therefore, the