Commit e6dbb39b authored by tom's avatar tom

unpin api host

parent f8f97421
......@@ -35,8 +35,7 @@ const baseUrl = [
appPort && ':' + appPort,
].filter(Boolean).join('');
const authUrl = getEnvValue(process.env.NEXT_PUBLIC_AUTH_URL) || baseUrl;
// const apiHost = getEnvValue(process.env.NEXT_PUBLIC_API_HOST);
const apiHost = 'eth-goerli.blockscout.com';
const apiHost = getEnvValue(process.env.NEXT_PUBLIC_API_HOST);
const apiSchema = getEnvValue(process.env.NEXT_PUBLIC_API_PROTOCOL) || 'https';
const apiPort = getEnvValue(process.env.NEXT_PUBLIC_API_PORT);
const apiEndpoint = apiHost ? [
......
// import appConfig from 'configs/app/config';
import appConfig from 'configs/app/config';
// FIXME
// I was not able to figure out how to send CORS with credentials from localhost
// unsuccessfully tried different ways, even custom local dev domain
// so for local development we have to use next.js api as proxy server
export default function isNeedProxy() {
return true;
// return appConfig.host === 'localhost' && appConfig.host !== appConfig.api.host;
return appConfig.host === 'localhost' && appConfig.host !== appConfig.api.host;
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment