我有一个React.js应用程序,我正在cPanel上托管该应用程序,该应用程序不允许后端。想知道我是否可以让sendgrid在没有后端的情况下工作?有人有没有以前工作过?
我目前收到以下错误:
Access to fetch at 'https://api.sendgrid.com/v3/mail/send' from origin '
https://angelospizzaharvard.com' has been blocked by CORS policy: Response
to preflight request doesn't pass access control check: The 'Access-Control-
Allow-Origin' header has a value 'https://sendgrid.api-docs.io' that is not
equal to the supplied origin.
Have the server send the header with a valid
value, or, if an opaque response serves your needs, set the request's mode
to 'no-cors' to fetch the resource with CORS disabled.
Navbar.js:427 TypeError: Failed to fetch
从此链接sendgrid docs,似乎只能从后端服务器调用它。