Commit f42ec931 authored by tom's avatar tom

revert proxy changes

parent 797aca0d
......@@ -77,7 +77,7 @@ frontend:
NEXT_PUBLIC_FEATURED_NETWORKS:
_default: https://raw.githubusercontent.com/blockscout/frontend-configs/dev/configs/featured-networks/eth-goerli.json
NEXT_PUBLIC_API_HOST:
_default: eth-goerli.blockscout.com
_default: blockscout-main.k8s-dev.blockscout.com
NEXT_PUBLIC_STATS_API_HOST:
_default: https://stats-test.k8s-dev.blockscout.com/
NEXT_PUBLIC_VISUALIZE_API_HOST:
......
// 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() {
// eslint-disable-next-line no-restricted-properties
if (process.env.NEXT_PUBLIC_APP_INSTANCE === 'pw') {
return false;
}
return true;
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