javascript - 当我尝试通过 google API、JS React 获取日历事件时出错

标签 javascript reactjs google-api google-calendar-api google-oauth

出于某种原因;尝试通过 google API 获取我的日历事件时出现错误。我用 JS 编写代码并使用 React,但不知道为什么它不起作用。

我将 token 存储在 sessionStorage 中,并确实获取了有关用户的个人信息,例如姓名电子邮件等,但我无法继续获取日历事件。请帮忙!

我不确定你到底想在我的应用程序中看到什么,但请告诉我,我会提供这些东西,因为我不想上传整个项目,哈哈

https://gyazo.com/37433e19f07e441adf368d1bbcad78e6

最佳答案

也许尝试返回 res.send,因为你使用 async/await,它返回 promise

关于javascript - 当我尝试通过 google API、JS React 获取日历事件时出错,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/51818104/

相关文章:

javascript - AJAX:将 <li> 添加到现有的

JavaScript : send actual html code to url

javascript - 2D Canvas : specify `arc()` radius units

reactjs - Material UI 组件中的媒体查询

node.js - 使用 API 创建 Google 日历事件不会创建环聊链接

node.js - Node.js 中的 googleapi/drive

javascript - HTML 表单 - 按 'Enter' 时执行脚本,不提交

javascript - React 如何在调用 onSubmit 时绑定(bind)到组件

reactjs - 渲染 HOC(组件)而不更改 JSX 中的组件名称

python - oauth2client.clientsecrets.InvalidClientSecretsError : Missing property "redirect_uris" in a client type of "web"