-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Move buildURL and related methods to a mixin #2812
Conversation
This seems great to me! I wonder how this will affect the website. I think we still want the methods to show up on the documentation for DS.Model. Do you have ruby installed? If so can you try building this in the website repo and post some screenshots of the doc output? |
I do have Ruby installed, but have never generated the API docs before. I'll try following the instructions at https://github.com/emberjs/website/blob/master/README.md and post the results. |
Should we be exporting the |
@amiel I suspect @fivetanley is correct and the |
Hmmm, I can't get the docs to generate:
Should there be a I'm using ruby 2.1.0. |
This is my first step towards emberjs/rfcs#4. The intent here is to separate url building from the RESTAdapter so that it can eventually be included in other adapters and hold the logic for the path templating described in emberjs/rfcs#4.
804e431
to
6835936
Compare
@bmac @fivetanley I've tried for a while to generate the API docs to verify. Since I couldn't get anything working, I've just made the changes you suggested. I wasn't going to export |
@@ -0,0 +1,111 @@ | |||
var get = Ember.get; | |||
|
|||
export default Ember.Mixin.create({ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This will need a doc block at the top with an @class BuildURLMixin
annotation for the methods below to get correctly attributed to the correct class.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@bmac ok, I've added this, and some documentation for how to use BuildURLMixin
. It is not very thorough, but my goal is to completely change the way url building is done (with url templates), and I don't want to spend too much time improving documentation for something that will soon be obsolete.
774bb10
to
31faddd
Compare
31faddd
to
486f768
Compare
Ok, I've got the docs building now, thanks @rwjblue. Here's what it looks like now: |
Move buildURL and related methods to a mixin
This is my first step towards emberjs/rfcs#4.
The intent here is to separate url building from the RESTAdapter so that
it can eventually be included in other adapters and hold the logic for the
path template concept described in emberjs/rfcs#4.
Even though it's a fairly small change, I've written this pull request to: