Ask a Question

Trouble with servers stanza

howardlander
New Contributor

Trouble with servers stanza

Hi all,

 

I have an OpenAPI yaml file.  As soon as I add a servers stanza like the following:

 

servers:
-url: https://xxxxx/renci.org

 

I can't render the page using swagger-ui anymore.  I'm using this:

 

npx open-swagger-ui myYAMLFile.yaml

 

The error in the web console is:

react-dom.production.min.js:216 TypeError: e.get is not a function
at servers.jsx:109:55
at immutable.js:4492:23
at immutable.js:2699:43
at St.__iterate (immutable.js:2206:13)
at qt.__iterate (immutable.js:2698:25)
at qt.findEntry (immutable.js:4491:12)
at qt.find (immutable.js:4375:24)
at p.render (servers.jsx:109:42)
at Hi (react-dom.production.min.js:187:188)
at Wi (react-dom.production.min.js:186:173)

 

If I comment out the servers stanza it works as expected.

 

Any thoughts on how to fix this?

 

Thanks in advance for any help, Apologies if this is the wrong forum for this question.

 

Howard

 

1 REPLY 1
howardlander
New Contributor

OK, so I'm an idiot. For the sake of any other of my tribe, there needs to be a space between the "-" and the "url" 😀

cancel
Showing results for 
Search instead for 
Did you mean: