Oliver Eyton-Williams 1130a1c0df
chore: update to beta of react-instantsearch-dom (#36843)
* chore: update to beta of react-instantsearch-dom

* feat: use .env variables for search keys
2019-10-04 18:03:20 +02:00

32 lines
648 B
JavaScript

const path = require('path');
if (process.env.FREECODECAMP_NODE_ENV !== 'production') {
const envPath = path.resolve(__dirname, '../.env');
require('dotenv').config({ path: envPath });
}
const {
HOME_LOCATION: home,
API_LOCATION: api,
FORUM_LOCATION: forum,
NEWS_LOCATION: news,
LOCALE: locale,
STRIPE_PUBLIC: stripePublicKey,
ALGOLIA_APP_ID: algoliaAppId,
ALGOLIA_API_KEY: algoliaAPIKey
} = process.env;
const locations = {
homeLocation: home,
apiLocation: api,
forumLocation: forum,
newsLocation: news
};
module.exports = Object.assign(locations, {
locale,
stripePublicKey,
algoliaAppId,
algoliaAPIKey
});