Created
June 21, 2022 09:34
-
-
Save caprica/1daff59d4b5ad9737d33f6dccdca2bda to your computer and use it in GitHub Desktop.
Banish Spring Boot HATEOAS ugly responses
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Instead of returning JSON with "_embedded" HATEOAS structures (e.g. when returning PagedModel), use a nicer format | |
# with "links", "content" and "page". | |
# | |
# The media type on the controller method should be "application/json", NOT "application/hal+json". | |
spring.hateoas.use-hal-as-default-json-media-type=false |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment