Open RichardLitt opened 8 years ago
Yes. It's not "officially" supported but you should be able to do something like the following:
options = {
emitter: {
emit: function(eventType, method, path, data, options) {
console.log(arguments);
}
}
};
octo = require('octokat')(options)
octo.repos('philschatz/octokat.js').fetch()
You can try it out by changing the first line at https://tonicdev.com/npm/octokat
Hope that helps, and let me know if it works for you!
I am continually running into rate limits for the GitHub API, and it's pretty hard for me to diagnose my issues easily. In part, this is because my code has hundred of API calls, so it makes sense. I'd like to have a better picture into my rate limits as they happen by console logging what requests I am making and what rate limits I have left, after each one.
Someone pointed me to this line in the code. Is there an easy way for me to use this?
Thanks.