UNPKG

@loopback/docs

Version:

Documentation files rendered at [https://loopback.io](https://loopback.io)

65 lines (34 loc) 995 B
--- lang: en title: 'API docs: rest.bodyparser.supports' keywords: LoopBack 4.0, LoopBack 4, Node.js, TypeScript, OpenAPI sidebar: lb4_sidebar editurl: https://github.com/loopbackio/loopback-next/tree/master/packages/rest permalink: /doc/en/lb4/apidocs.rest.bodyparser.supports.html --- <!-- Do not edit this file. It is automatically generated by API Documenter. --> [Home](./index.md) &gt; [@loopback/rest](./rest.md) &gt; [BodyParser](./rest.bodyparser.md) &gt; [supports](./rest.bodyparser.supports.md) ## BodyParser.supports() method Indicate if the given media type is supported **Signature:** ```typescript supports(mediaType: string): boolean; ``` ## Parameters <table><thead><tr><th> Parameter </th><th> Type </th><th> Description </th></tr></thead> <tbody><tr><td markdown="1"> mediaType </td><td markdown="1"> string </td><td markdown="1"> Media type </td></tr> </tbody></table> **Returns:** boolean