mirror of
https://github.com/zulip/zulip.git
synced 2025-11-18 12:54:58 +00:00
api docs: Render example responses as with JSON codehilite.
This makes the example responses a lot prettier visually.
This commit is contained in:
@@ -337,7 +337,7 @@ class APICodeExamplesPreprocessor(Preprocessor):
|
|||||||
fixture_json = json.dumps(fixture_dict, indent=4, sort_keys=True,
|
fixture_json = json.dumps(fixture_dict, indent=4, sort_keys=True,
|
||||||
separators=(',', ': '))
|
separators=(',', ': '))
|
||||||
|
|
||||||
fixture.append('```')
|
fixture.append('``` json')
|
||||||
fixture.extend(fixture_json.splitlines())
|
fixture.extend(fixture_json.splitlines())
|
||||||
fixture.append('```')
|
fixture.append('```')
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user