diff --git a/src/components/Endpoint/Endpoint.tsx b/src/components/Endpoint/Endpoint.tsx index 9e9a5f92..9579eeca 100644 --- a/src/components/Endpoint/Endpoint.tsx +++ b/src/components/Endpoint/Endpoint.tsx @@ -67,6 +67,7 @@ export class Endpoint extends React.Component { const normalizedUrl = options.expandDefaultServerVariables ? expandDefaultServerVariables(server.url, server.variables) : server.url; + const basePath = getBasePath(normalizedUrl); return ( @@ -74,7 +75,9 @@ export class Endpoint extends React.Component { {hideHostname || options.hideHostname - ? getBasePath(normalizedUrl) + ? basePath === '/' + ? '' + : basePath : normalizedUrl} {operation.path}