api-console icon indicating copy to clipboard operation
api-console copied to clipboard

types are not in same order as raml file

Open pete-lemire opened this issue 5 years ago • 4 comments

screen shot 2019-01-31 at 6 35 22 pm screen shot 2019-01-31 at 6 36 11 pm

pete-lemire avatar Jan 31 '19 23:01 pete-lemire

Hi, Thank you for issue report. API console iterates over the array of declarations found in the AMF model (see here: https://github.com/advanced-rest-client/api-navigation/blob/stage/api-navigation.html#L747). Then it iterates over list of references to do the same (references are external files like fragments containing among others RAML types). There's no sorting function used in navigation. I will bring this issue onto attention of AMF team to see if this can be fixed in the AMF model.

jarrodek avatar Feb 05 '19 01:02 jarrodek

Thank you @jarrodek

pete-lemire avatar Feb 11 '19 13:02 pete-lemire

Same complaint. At least lexicographic ordering is always better than random.

marcadella avatar Apr 24 '19 10:04 marcadella

According to AMF team types are actually in right order. It might get weird when you apply external types and / or libraries. I am not sure myself how this is exactly processed but the console also includes types from external sources in navigation and it may produce some unexpected results in terms of ordering. However the console use the order defined in AMF model.

jarrodek avatar Apr 26 '19 21:04 jarrodek