PostgREST – REST API from any PostgreSQL database
1–10 of 210 posts
Re: PostgREST – REST API from any PostgreSQL database
#2Re: PostgREST – REST API from any PostgreSQL database
#3[1]: http://jsonapi.org/
Re: PostgREST – REST API from any PostgreSQL database
#4Should add some header to say that it's JSON, or add a .json file extension for the main page data.
Very interesting project though.
Re: PostgREST – REST API from any PostgreSQL database
#5Example is broken. It's returning a JSON doc, so if you leave it then return, some browsers will just return the cached JSON (as text). Should add some header to say that it's JSON, or add a .json file extension for the main page data. Very interesting project though.
The server sends `Content-Type: application/json` and provides no header related to caching. Browsers that do anything but fetching the resource again are not spec compliant.
Also, the only browser to ever look at the extension of a file in the URL was IE (https://msdn.microsoft.com/en-us/library/ms775147(v=vs.85).a...) and they have long since stopped doing that as all it was doing was cause security issues and screw with web developers.
Re: PostgREST – REST API from any PostgreSQL database
#6I also very much liked the idea of using `Range` headers for pagination (which should be out-of-band but rarely is).
I'm not convinced that this is the future of web development, but it's a nice refreshing view that contains a few very practical ideas.
Even if you don't care about this at all, spend the 12 minutes to watch the introductory presentation.
Re: PostgREST – REST API from any PostgreSQL database
#7Is the JSON JSON API [1] compliant, perchance? [1]: http://jsonapi.org/
and what's with the garbage pretty-print of the json on that page. Yuck!
Re: PostgREST – REST API from any PostgreSQL database
#8Example is broken. It's returning a JSON doc, so if you leave it then return, some browsers will just return the cached JSON (as text). Should add some header to say that it's JSON, or add a .json file extension for the main page data. Very interesting project though.
>Should add some header to say that it's JSON, or add a .json file extension for the main page data. The server sends `Content-Type: application/json` and provides no header related to caching. Browsers that do anything but fetching the resource again are not spec compliant. Also, the only browser to ever look at the extension of a file in the URL was IE ( https://msdn.microsoft.com/en-us/library/ms775147(v=vs.85).a.…
Re: PostgREST – REST API from any PostgreSQL database
#9Re: PostgREST – REST API from any PostgreSQL database
#10Earlier quoted context omitted.
>Should add some header to say that it's JSON, or add a .json file extension for the main page data. The server sends `Content-Type: application/json` and provides no header related to caching. Browsers that do anything but fetching the resource again are not spec compliant. Also, the only browser to ever look at the extension of a file in the URL was IE ( https://msdn.microsoft.com/en-us/library/ms775147(v=vs.85).a.…
Correct answer. The demo is doing everything right, parent seems confused. Browsers also don't have any special regard for '.json' in the path. The path can be anything; the path doesn't suggest anything about content-type or caching.
Browsers shouldn't care about file extensions, ever, but some versions of IE did.