@types/express

  • Version 4.17.12
  • Published
  • 12.4 kB
  • 4 dependencies
  • MIT license

Install

npm i @types/express
yarn add @types/express
pnpm add @types/express

Overview

TypeScript definitions for Express

Index

Variables

variable application

var application: Application;
  • These are the exposed prototypes.

variable json

var json: any;
  • This is a built-in middleware function in Express. It parses incoming requests with JSON payloads and is based on body-parser. 4.16.0

variable raw

var raw: any;
  • This is a built-in middleware function in Express. It parses incoming requests with Buffer payloads and is based on body-parser. 4.17.0

variable request

var request: Request<any, any, any, any, Record<string, any>>;

    variable response

    var response: Response<any, Record<string, any>>;

      variable static

      var static: any;
      • This is a built-in middleware function in Express. It serves static files and is based on serve-static.

      variable text

      var text: any;
      • This is a built-in middleware function in Express. It parses incoming requests with text payloads and is based on body-parser. 4.17.0

      variable urlencoded

      var urlencoded: any;
      • This is a built-in middleware function in Express. It parses incoming requests with urlencoded payloads and is based on body-parser. 4.16.0

      Functions

      function e

      e: typeof e;
      • Creates an Express application. The express() function is a top-level function exported by the express module.

      function query

      query: (options: qs.IParseOptions | typeof qs.parse) => Handler;
      • This is a built-in middleware function in Express. It parses incoming request query parameters.

      function Router

      Router: (options?: RouterOptions) => any;

        Interfaces

        interface Application

        interface Application extends core.Application {}

          interface CookieOptions

          interface CookieOptions extends core.CookieOptions {}

            interface Errback

            interface Errback extends core.Errback {}

              interface ErrorRequestHandler

              interface ErrorRequestHandler<
              P = core.ParamsDictionary,
              ResBody = any,
              ReqBody = any,
              ReqQuery = core.Query,
              Locals extends Record<string, any> = Record<string, any>
              > extends core.ErrorRequestHandler<P, ResBody, ReqBody, ReqQuery, Locals> {}

                interface Express

                interface Express extends core.Express {}

                  interface Handler

                  interface Handler extends core.Handler {}

                    interface IRoute

                    interface IRoute extends core.IRoute {}

                      interface IRouter

                      interface IRouter extends core.IRouter {}

                        interface IRouterHandler

                        interface IRouterHandler<T> extends core.IRouterHandler<T> {}

                          interface IRouterMatcher

                          interface IRouterMatcher<T> extends core.IRouterMatcher<T> {}

                            interface MediaType

                            interface MediaType extends core.MediaType {}

                              interface NextFunction

                              interface NextFunction extends core.NextFunction {}

                                interface Request

                                interface Request<
                                P = core.ParamsDictionary,
                                ResBody = any,
                                ReqBody = any,
                                ReqQuery = core.Query,
                                Locals extends Record<string, any> = Record<string, any>
                                > extends core.Request<P, ResBody, ReqBody, ReqQuery, Locals> {}

                                  interface RequestHandler

                                  interface RequestHandler<
                                  P = core.ParamsDictionary,
                                  ResBody = any,
                                  ReqBody = any,
                                  ReqQuery = core.Query,
                                  Locals extends Record<string, any> = Record<string, any>
                                  > extends core.RequestHandler<P, ResBody, ReqBody, ReqQuery, Locals> {}

                                    interface RequestParamHandler

                                    interface RequestParamHandler extends core.RequestParamHandler {}

                                      interface Response

                                      interface Response<
                                      ResBody = any,
                                      Locals extends Record<string, any> = Record<string, any>
                                      > extends core.Response<ResBody, Locals> {}

                                        interface Router

                                        interface Router extends core.Router {}

                                          interface RouterOptions

                                          interface RouterOptions {}

                                            property caseSensitive

                                            caseSensitive?: boolean;
                                            • Enable case sensitivity.

                                            property mergeParams

                                            mergeParams?: boolean;
                                            • Preserve the req.params values from the parent router. If the parent and the child have conflicting param names, the child’s value take precedence.

                                              false 4.5.0

                                            property strict

                                            strict?: boolean;
                                            • Enable strict routing.

                                            interface Send

                                            interface Send extends core.Send {}

                                              Package Files (1)

                                              Dependencies (4)

                                              Dev Dependencies (0)

                                              No dev dependencies.

                                              Peer Dependencies (0)

                                              No peer dependencies.

                                              Badge

                                              To add a badge like this onejsDocs.io badgeto your package's README, use the codes available below.

                                              You may also use Shields.io to create a custom badge linking to https://www.jsdocs.io/package/@types/express.

                                              • Markdown
                                                [![jsDocs.io](https://img.shields.io/badge/jsDocs.io-reference-blue)](https://www.jsdocs.io/package/@types/express)
                                              • HTML
                                                <a href="https://www.jsdocs.io/package/@types/express"><img src="https://img.shields.io/badge/jsDocs.io-reference-blue" alt="jsDocs.io"></a>