Faster github api usage #310

Merged
merged 2 commits into from Apr 5, 2013

Conversation

Projects
None yet
3 participants
Owner

dhcole commented Apr 4, 2013

Makes better use of the github api with updates to github.js

  • Update github.js. Removes cache busting timestamp, improves repo.contents
  • Use repo.contents instead of repose.read to eliminate extra ajax request

See 0.75 - 1.25 second decrease in load time on post pages.

@mikemorris @tristen want to test this?

Owner

tristen commented Apr 5, 2013

Tested. Looks good to me!

Owner

michael commented Apr 5, 2013

Had a look too. It's working fine. Merged.

@michael michael pushed a commit that referenced this pull request Apr 5, 2013

Michael Aufreiter Merge pull request #310 from prose/faster
Faster github api usage
c655c31

@michael michael merged commit c655c31 into gh-pages Apr 5, 2013

Owner

michael commented Apr 5, 2013

Woops sorry, I've somehow overlooked that this is a pull request on prose/prose not michael/github. Testing on prose.io now to see if anything bad happened.

Owner

michael commented Apr 5, 2013

All fine. The only thing I noticed is the delay until another API request reflects the change (but this is a known issue - pretty sure).

To reproduce:

  • Open and edit a file
  • Save it
  • Reload

Changes are not visible. They'll be come visible when you reload a couple of minutes later. Just double-check this not related to optimizations you made.

Owner

dhcole commented Apr 5, 2013

Yea I'm thinking cache busting should be addressed by prose so that its
only done on save, when we know there should be new content. Thanks for
taking a look. Will get this sorted out and into the main GitHub.js.

On Apr 5, 2013, at 6:51 AM, Michael Aufreiter notifications@github.com
wrote:

All fine. The only thing I noticed is the delay until another API request
reflects the change (but this is a known issue - pretty sure).

To reproduce:

  • Open and edit a file
  • Save it
  • Reload

Changes are not visible. They'll be come visible when you reload a couple
of minutes later. Just double-check this not related to optimizations you
made.


Reply to this email directly or view it on
GitHubhttps://github.com/prose/prose/pull/310#issuecomment-15949633
.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment