Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Going to be full-featured? #40

Closed
hesalx opened this issue Nov 12, 2014 · 3 comments
Closed

Going to be full-featured? #40

hesalx opened this issue Nov 12, 2014 · 3 comments

Comments

@hesalx
Copy link
Contributor

hesalx commented Nov 12, 2014

I'm really excited with jsonapi, it fits my needs with elegance and simplicity. This implementation seems the best for my needs and looks promising.

I thought about several features so decided to ask more general question. Will it be a full-featured implementation with all the features the spec provides? Including optional enabling of optional features (no force usage) and so on... Because it looks like some other implementations chosen one of "possible ways" (forced a concrete set of optional features).

As a developer I wish to know if I can rely on this implementation. (Also would be glad to provide some PRs if so).

I was thinking about URL Templates ("links" object) primarily. But now I'm waiting for the result of json-api/json-api#311.

@lgebhardt
Copy link
Member

@arantir, the plan is to provide options for most of the major features in JSON API. I have a branch started, https://github.com/cerebris/jsonapi-resources/tree/toplevel_links, that started the configuration options for URL Templates. It's not complete, but will give you an idea of how I plan to implement the configuration options. This branch may never get merged because of json-api/json-api#311.

Here's a config example using that branch

JSONAPI.configure do |config|
  config.resource_links_style = :collection_objects
end

Look in https://github.com/cerebris/jsonapi-resources/blob/toplevel_links/lib/jsonapi/configuration.rb for more options. Again, this will most likely change as a result of json-api#311.

PRs for fixes and new features are most welcome. I suspect I won't add support for every feature myself, but if it's in the spec I'd like to support it in JR. That's one more reason to keep JSON API nice and tight.

@lgebhardt
Copy link
Member

I should add that one area I'm hoping to focus on is performance. Some of the options, such as turning off ids for has_many associations and not doing side loading of data should allow for a much more efficient serializer with much less load on the database. Of course this will be at the expense of more requests, so it making things configurable is very important. One size certainly doesn't fit all.

@lgebhardt
Copy link
Member

Closing

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants