expressjs.com
expressjs.com copied to clipboard
5.x docs are missing some documentation added in late 4.x versions
@paulhiggs in https://github.com/expressjs/express/issues/6479 reported that express.text() is missing from 5.x docs.
express.text() and express.raw() were added in Express 4.17.0. The 4.x documentation reflects that (18dfac1bbd053fb99cba9ff137cb5a5e0c67d5fe, 958e581dbea384dca6bf4a62020762bb0f1ab1dc, b49ab1b94a34e37c791ec661b66ffac5a37803a5), but 5.x documentation has not been updated after changes from 4.17.0/4.17.1 were merged into 5.0/5.x branches (https://github.com/expressjs/express/commit/121fe9982b62d2b1760ec9cb148c19bc5f17255b).
TODO:
- [x] Add
express.text()to 5.x API docs (#1883) - [x] Add
express.raw()to 5.x API docs (#1883) - [x] Review 4.x documentation changes and check if more changes to late 4.x versions that were later included in 5.x are missing in 5.x docs (it has already been tracked in #1479)
- [x] 4.18 added
priorityoption tores.cookie()androotoption tores.download()(5c98ee4e949fc69b9dbc89b839c137b7a2eea3fc) (#1886) - [x] #1402 improved
req.acceptsLanguages()docs, but only the 4.x version (#1886) - [x] 5e918ea3a98edcc9a4f9698ca0994f3c6fc1f4e3 added warning boxes to
res.render()andapp.render()(#1886) - [x] fcaca7fcc6f182a8821352a94a88f9fc10320cbb added warnings about
locals(#1886) - [x] #1456 documented the
partitionedoption ofres.cookie()(#1886) - [x] 4.x and 5.x had slightly different (and incompatible) examples for
router.param(fn), which doesn't even exist in Express 5 (#1884) - [x] a5ca5b0edf437c066f7a1dfa5dc11bc4cb9981e1 changed
req.bodydocumentation (4.x), removing references tomulterandbody-parserand presenting built-in middleware. (#1886) - [x] #1063 expanded
res.cookie()docs, showing how to set multiple cookies (#1886)
- [x] 4.18 added
Other differences include:
- [ ] Admonitions are used inconsistently (e.g. in 4.x
express.static(), but not in 5.x; there are still many.doc-box<div>s) - [ ] One warning about open redirect was removed in 5.x
res.location()in #1835 - [ ] In 4.x most strings in comments use single quotes, but in 5.x many more use double quotes (and one in
res.type()has a typo) - [ ] In some 5x docs available in Express 4.?? onwards or similar notes have been removed (or never added), but in most places those still exist
PRs welcome