有没有办法让ApolloClient接受来自使用自签名证书的服务器的请求?
import ApolloClient from 'apollo-boost';
const client = new ApolloClient({
uri: `https://${window.location.hostname}:8080/graphql`,
rejectUnauthorized: false
});
- rejectUnauthorized: false不起作用
请求错误: OPTIONS https://localhost:8080/graphql net::ERR_CERT_AUTHORITY_INVALID