{"action":"created","issue":{"url":"https://api.github.com/repos/rubenCodeforges/ng-gapi/issues/62","repository_url":"https://api.github.com/repos/rubenCodeforges/ng-gapi","labels_url":"https://api.github.com/repos/rubenCodeforges/ng-gapi/issues/62/labels{/name}","comments_url":"https://api.github.com/repos/rubenCodeforges/ng-gapi/issues/62/comments","events_url":"https://api.github.com/repos/rubenCodeforges/ng-gapi/issues/62/events","html_url":"https://github.com/rubenCodeforges/ng-gapi/issues/62","id":356725469,"node_id":"MDU6SXNzdWUzNTY3MjU0Njk=","number":62,"title":"Uncaught TypeError: gapi.client.HttpBatch is not a constructor","user":{"login":"SCP002","id":22541678,"node_id":"MDQ6VXNlcjIyNTQxNjc4","avatar_url":"https://avatars3.githubusercontent.com/u/22541678?v=4","gravatar_id":"","url":"https://api.github.com/users/SCP002","html_url":"https://github.com/SCP002","followers_url":"https://api.github.com/users/SCP002/followers","following_url":"https://api.github.com/users/SCP002/following{/other_user}","gists_url":"https://api.github.com/users/SCP002/gists{/gist_id}","starred_url":"https://api.github.com/users/SCP002/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SCP002/subscriptions","organizations_url":"https://api.github.com/users/SCP002/orgs","repos_url":"https://api.github.com/users/SCP002/repos","events_url":"https://api.github.com/users/SCP002/events{/privacy}","received_events_url":"https://api.github.com/users/SCP002/received_events","type":"User","site_admin":false},"labels":[{"id":593006670,"node_id":"MDU6TGFiZWw1OTMwMDY2NzA=","url":"https://api.github.com/repos/rubenCodeforges/ng-gapi/labels/bug","name":"bug","color":"ee0701","default":true}],"state":"open","locked":false,"assignee":{"login":"rubenCodeforges","id":6032797,"node_id":"MDQ6VXNlcjYwMzI3OTc=","avatar_url":"https://avatars2.githubusercontent.com/u/6032797?v=4","gravatar_id":"","url":"https://api.github.com/users/rubenCodeforges","html_url":"https://github.com/rubenCodeforges","followers_url":"https://api.github.com/users/rubenCodeforges/followers","following_url":"https://api.github.com/users/rubenCodeforges/following{/other_user}","gists_url":"https://api.github.com/users/rubenCodeforges/gists{/gist_id}","starred_url":"https://api.github.com/users/rubenCodeforges/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rubenCodeforges/subscriptions","organizations_url":"https://api.github.com/users/rubenCodeforges/orgs","repos_url":"https://api.github.com/users/rubenCodeforges/repos","events_url":"https://api.github.com/users/rubenCodeforges/events{/privacy}","received_events_url":"https://api.github.com/users/rubenCodeforges/received_events","type":"User","site_admin":false},"assignees":[{"login":"rubenCodeforges","id":6032797,"node_id":"MDQ6VXNlcjYwMzI3OTc=","avatar_url":"https://avatars2.githubusercontent.com/u/6032797?v=4","gravatar_id":"","url":"https://api.github.com/users/rubenCodeforges","html_url":"https://github.com/rubenCodeforges","followers_url":"https://api.github.com/users/rubenCodeforges/followers","following_url":"https://api.github.com/users/rubenCodeforges/following{/other_user}","gists_url":"https://api.github.com/users/rubenCodeforges/gists{/gist_id}","starred_url":"https://api.github.com/users/rubenCodeforges/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rubenCodeforges/subscriptions","organizations_url":"https://api.github.com/users/rubenCodeforges/orgs","repos_url":"https://api.github.com/users/rubenCodeforges/repos","events_url":"https://api.github.com/users/rubenCodeforges/events{/privacy}","received_events_url":"https://api.github.com/users/rubenCodeforges/received_events","type":"User","site_admin":false}],"milestone":null,"comments":17,"created_at":"2018-09-04T09:26:27Z","updated_at":"2018-10-02T13:45:41Z","closed_at":null,"author_association":"NONE","body":"Readme describes a way to work with HttpBatch like this:\r\n```ts\r\nexport class FooService {\r\n    constructor(gapiService: GoogleApiService) {\r\n        gapiService.onLoad().subscribe(()=> {\r\n           const myBatch: HttpBatch = new HttpBatch();\r\n           myBatch.add(\r\n               // your request\r\n           );\r\n        });\r\n    }\r\n}\r\n```\r\n\r\nBut for me it's unclear where HttpBatch reference come from.\r\n\r\n---\r\nIf use alias:\r\n```ts\r\nimport HttpBatch = gapi.client.HttpBatch;\r\n\r\n// ...\r\n\r\nconst batch: HttpBatch = new HttpBatch();\r\n```\r\nI got \r\n\r\n> Uncaught ReferenceError: gapi is not defined\r\n\r\nIf use full path:\r\n```ts\r\nconst batch: gapi.client.HttpBatch = new gapi.client.HttpBatch();\r\n```\r\nI got\r\n\r\n> Uncaught TypeError: gapi.client.HttpBatch is not a constructor\r\n\r\n---\r\nSure, it all happens even inside of gapiService.onLoad() subscribe callback.\r\n\r\nHow can this problem be solved?\r\n\r\nThanks in advance!"},"comment":{"url":"https://api.github.com/repos/rubenCodeforges/ng-gapi/issues/comments/426279394","html_url":"https://github.com/rubenCodeforges/ng-gapi/issues/62#issuecomment-426279394","issue_url":"https://api.github.com/repos/rubenCodeforges/ng-gapi/issues/62","id":426279394,"node_id":"MDEyOklzc3VlQ29tbWVudDQyNjI3OTM5NA==","user":{"login":"rubenCodeforges","id":6032797,"node_id":"MDQ6VXNlcjYwMzI3OTc=","avatar_url":"https://avatars2.githubusercontent.com/u/6032797?v=4","gravatar_id":"","url":"https://api.github.com/users/rubenCodeforges","html_url":"https://github.com/rubenCodeforges","followers_url":"https://api.github.com/users/rubenCodeforges/followers","following_url":"https://api.github.com/users/rubenCodeforges/following{/other_user}","gists_url":"https://api.github.com/users/rubenCodeforges/gists{/gist_id}","starred_url":"https://api.github.com/users/rubenCodeforges/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rubenCodeforges/subscriptions","organizations_url":"https://api.github.com/users/rubenCodeforges/orgs","repos_url":"https://api.github.com/users/rubenCodeforges/repos","events_url":"https://api.github.com/users/rubenCodeforges/events{/privacy}","received_events_url":"https://api.github.com/users/rubenCodeforges/received_events","type":"User","site_admin":false},"created_at":"2018-10-02T13:45:41Z","updated_at":"2018-10-02T13:45:41Z","author_association":"OWNER","body":"All the errors you get are api errors , they dont relate to ng-gapi.\r\n\r\n```\r\nconst params: Object = {\r\n// ...\r\n};\r\n```\r\nRegarding this , i dont know what that is and where you got it.\r\n\r\nI would advise you to read Google API Documentation."}}
{"actor":{"display_login":"rubenCodeforges"}}