{"action":"created","issue":{"url":"https://api.github.com/repos/WebReflection/jsgtk/issues/8","repository_url":"https://api.github.com/repos/WebReflection/jsgtk","labels_url":"https://api.github.com/repos/WebReflection/jsgtk/issues/8/labels{/name}","comments_url":"https://api.github.com/repos/WebReflection/jsgtk/issues/8/comments","events_url":"https://api.github.com/repos/WebReflection/jsgtk/issues/8/events","html_url":"https://github.com/WebReflection/jsgtk/pull/8","id":226942829,"number":8,"title":"Add support for axios","user":{"login":"jaszhix","id":6859057,"avatar_url":"https://avatars0.githubusercontent.com/u/6859057?v=3","gravatar_id":"","url":"https://api.github.com/users/jaszhix","html_url":"https://github.com/jaszhix","followers_url":"https://api.github.com/users/jaszhix/followers","following_url":"https://api.github.com/users/jaszhix/following{/other_user}","gists_url":"https://api.github.com/users/jaszhix/gists{/gist_id}","starred_url":"https://api.github.com/users/jaszhix/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jaszhix/subscriptions","organizations_url":"https://api.github.com/users/jaszhix/orgs","repos_url":"https://api.github.com/users/jaszhix/repos","events_url":"https://api.github.com/users/jaszhix/events{/privacy}","received_events_url":"https://api.github.com/users/jaszhix/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":3,"created_at":"2017-05-08T05:38:49Z","updated_at":"2017-05-08T10:53:02Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/WebReflection/jsgtk/pulls/8","html_url":"https://github.com/WebReflection/jsgtk/pull/8","diff_url":"https://github.com/WebReflection/jsgtk/pull/8.diff","patch_url":"https://github.com/WebReflection/jsgtk/pull/8.patch"},"body":"These changes were needed to prevent exceptions when attempting to load Axios, a promise based AJAX library. An https module was created that aliases the http module, in order to prevent errors. SSL connections are not currently working with Axios, and after trying a few things with Soup, I am still unsure how that might be done.\r\n\r\nOther changes:\r\n\r\n- Add ability to require JSON files.\r\n- Polyfill setTimeout and clearTimeout.\r\n- Add a work around when modules use `Writable.call(this)` by selecting a default channel to write to.\r\n- Add the tty module and lazy polyfill a method to prevent the debug module from throwing errors.\r\n- Placeholder polyfills for Buffer.concat and Buffer.allocUnsafe, so Axios can write the response body."},"comment":{"url":"https://api.github.com/repos/WebReflection/jsgtk/issues/comments/299835852","html_url":"https://github.com/WebReflection/jsgtk/pull/8#issuecomment-299835852","issue_url":"https://api.github.com/repos/WebReflection/jsgtk/issues/8","id":299835852,"user":{"login":"jaszhix","id":6859057,"avatar_url":"https://avatars0.githubusercontent.com/u/6859057?v=3","gravatar_id":"","url":"https://api.github.com/users/jaszhix","html_url":"https://github.com/jaszhix","followers_url":"https://api.github.com/users/jaszhix/followers","following_url":"https://api.github.com/users/jaszhix/following{/other_user}","gists_url":"https://api.github.com/users/jaszhix/gists{/gist_id}","starred_url":"https://api.github.com/users/jaszhix/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jaszhix/subscriptions","organizations_url":"https://api.github.com/users/jaszhix/orgs","repos_url":"https://api.github.com/users/jaszhix/repos","events_url":"https://api.github.com/users/jaszhix/events{/privacy}","received_events_url":"https://api.github.com/users/jaszhix/received_events","type":"User","site_admin":false},"created_at":"2017-05-08T10:53:02Z","updated_at":"2017-05-08T10:53:02Z","body":"Thanks, I'll remove the timers next.\r\n\r\nThe Linux Mint recently rebased their version of GJS for support with mozjs38 because mozjs24 is being dropped in the next Ubuntu LTS. Unfortunately they're still supporting mozjs24 in their LMDE distro (Debian stable), and are still targeting JS for the oldest version. So instead of driving myself crazy I'm integrating your project in my extensions. What I want to do is get everything loaded in the global context, and have the extensions check if JSGTK is already loaded from another extension before loading it.\r\n\r\nJust curious, why are you storing String.prototype methods? I thought since its a native ES5 method and already on the prototype there's no performance bottleneck with ```'  string  '.trim()```. If you want performance, you could try replacing those ```forEach``` calls with [for loops](https://jsperf.com/for-vs-foreach/75). :)"}}
{"actor":{"display_login":"jaszhix"}}