feat: add hint for Request Path Variables to improve UX (#2873)

* feat: add hint for Request Path Variables to improve UX
This commit is contained in:
Krystian Marcisz 2024-08-22 14:10:39 +02:00 committed by GitHub
parent b1a140a4e0
commit ee8e162f3d
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -224,6 +224,16 @@ const QueryParams = ({ item, collection }) => {
: null}
</tbody>
</table>
{!(pathParams && pathParams.length) ?
<div className="title pr-2 py-3 mt-2 text-xs">
Hint: Path variables are automatically added whenever the
<code className="font-mono font-medium text-gray-700 dark:text-gray-400 mx-2">:name</code>
template is used in the URL, for example:
<code className="font-mono font-medium text-gray-700 dark:text-gray-400 mx-2">
https://example.com/v1/users/<span className="font-extrabold">:id</span>
</code>
</div>
: null}
</div>
</StyledWrapper>
);