UNPKG

@loopback/docs

Version:

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

35 lines (22 loc) 863 B
--- lang: en title: 'API docs: rest.getpathvariables' 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.getpathvariables.html --- <!-- Do not edit this file. It is automatically generated by API Documenter. --> [Home](./index.md) &gt; [@loopback/rest](./rest.md) &gt; [getPathVariables](./rest.getpathvariables.md) ## getPathVariables() function Get all path variables. For example, `/root/{foo}/bar` =<!-- -->&gt; `['foo']` <b>Signature:</b> ```typescript export declare function getPathVariables(path: string): RegExpMatchArray | null; ``` ## Parameters | Parameter | Type | Description | | --- | --- | --- | | path | string | | <b>Returns:</b> RegExpMatchArray \| null