Skip to content

Commit d670c41

Browse files
committed
frontend deploy
1 parent 07f3fa8 commit d670c41

2 files changed

Lines changed: 3 additions & 2 deletions

File tree

frontend/config.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
11
// This is client side config only - don't put anything in here that shouldn't be public!
22
export const endpoint = `http://localhost:4444`;
3+
export const prodEndpoint = `https://sick-ckw-prod.herokuapp.com/`;
34
export const perPage = 4;

frontend/lib/withData.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
import withApollo from 'next-with-apollo';
22
import ApolloClient from 'apollo-boost';
3-
import { endpoint } from '../config';
3+
import { endpoint, prodEndpoint } from '../config';
44
import { LOCAL_STATE_QUERY } from '../components/Cart';
55

66
function createClient({ headers }) {
77
return new ApolloClient({
8-
uri: process.env.NODE_ENV === 'development' ? endpoint : endpoint,
8+
uri: process.env.NODE_ENV === 'development' ? endpoint : prodEndpoint,
99
request: operation => {
1010
operation.setContext({
1111
fetchOptions: {

0 commit comments

Comments
 (0)