diff --git a/src/editor/components/modals/GeoModal/GeoModal.component.jsx b/src/editor/components/modals/GeoModal/GeoModal.component.jsx index 8e4a29e17..111a7e845 100644 --- a/src/editor/components/modals/GeoModal/GeoModal.component.jsx +++ b/src/editor/components/modals/GeoModal/GeoModal.component.jsx @@ -3,6 +3,7 @@ import { useState, useCallback, useEffect } from 'react'; import styles from './GeoModal.module.scss'; import { Mangnifier20Icon } from '../../../icons'; +import { firebaseConfig } from '../../../services/firebase.js'; import Modal from '../Modal.jsx'; import { Button, Input } from '../../components/index.js'; import { GoogleMap, useJsApiLoader, Marker } from '@react-google-maps/api'; @@ -43,7 +44,7 @@ const GeoModal = ({ isOpen, onClose }) => { }, []); const { isLoaded } = useJsApiLoader({ - googleMapsApiKey: process.env.FIREBASE_API_KEY + googleMapsApiKey: firebaseConfig.apiKey }); const onSaveHandler = () => { diff --git a/src/editor/index.js b/src/editor/index.js index 705d6de73..abe99e3a3 100644 --- a/src/editor/index.js +++ b/src/editor/index.js @@ -8,6 +8,7 @@ import { initCameras } from './lib/cameras'; import { createEntity } from './lib/entity'; import { Shortcuts } from './lib/shortcuts'; import { Viewport } from './lib/viewport'; +import { firebaseConfig } from './services/firebase.js'; import './style/index.scss'; import ReactGA from 'react-ga4'; @@ -325,7 +326,7 @@ Inspector.prototype = { } }; -ReactGA.initialize(process.env.FIREBASE_MEASUREMENT_ID); +ReactGA.initialize(firebaseConfig.measurementId); const inspector = (AFRAME.INSPECTOR = new Inspector()); export { inspector }; diff --git a/src/editor/services/firebase.js b/src/editor/services/firebase.js index c6a7f864c..8b8463717 100644 --- a/src/editor/services/firebase.js +++ b/src/editor/services/firebase.js @@ -18,4 +18,4 @@ const auth = getAuth(app); const storage = getStorage(app); const db = getFirestore(app); -export { auth, storage, db }; +export { firebaseConfig, auth, storage, db };