This commit is contained in:
Maciej Kotowski committed 2021-10-04 18:40:42 +02:00
1 parent fc6385ea37
commit 92ff30a6bb
4 files changed
+32 -11

No files matched your search

+23 -7
View File
@@ -14,6 +14,7 @@
"axios": "^0.22.0", "axios": "^0.22.0",
"bootstrap": "^5.1.1", "bootstrap": "^5.1.1",
"bootstrap-icons": "^1.5.0", "bootstrap-icons": "^1.5.0",
"dotenv": "^10.0.0",
"formik": "^2.2.9", "formik": "^2.2.9",
"gsap": "^3.8.0", "gsap": "^3.8.0",
"ol": "^6.8.1", "ol": "^6.8.1",
@@ -7129,11 +7130,11 @@
} }
}, },
"node_modules/dotenv": { "node_modules/dotenv": {
"version": "8.2.0", "version": "10.0.0",
"resolved": "https://registry.npmjs.org/dotenv/-/dotenv-8.2.0.tgz", "resolved": "https://registry.npmjs.org/dotenv/-/dotenv-10.0.0.tgz",
"integrity": "sha512-8sJ78ElpbDJBHNeBzUbUVLsqKdccaa/BXF1uPTw3GrvQTBgrQrtObr2mUrE38vzYd8cEv+m/JBfDLioYcfXoaw==", "integrity": "sha512-rlBi9d8jpv9Sf1klPjNfFAuWDjKLwTIJJ/VxtoTwIR6hnZxcEOQCZg2oIL3MWBYw5GpUDKOEnND7LXTbIpQ03Q==",
"engines": { "engines": {
"node": ">=8" "node": ">=10"
} }
}, },
"node_modules/dotenv-expand": { "node_modules/dotenv-expand": {
@@ -17010,6 +17011,14 @@
} }
} }
}, },
"node_modules/react-scripts/node_modules/dotenv": {
"version": "8.2.0",
"resolved": "https://registry.npmjs.org/dotenv/-/dotenv-8.2.0.tgz",
"integrity": "sha512-8sJ78ElpbDJBHNeBzUbUVLsqKdccaa/BXF1uPTw3GrvQTBgrQrtObr2mUrE38vzYd8cEv+m/JBfDLioYcfXoaw==",
"engines": {
"node": ">=8"
}
},
"node_modules/react-transition-group": { "node_modules/react-transition-group": {
"version": "4.4.2", "version": "4.4.2",
"resolved": "https://registry.npmjs.org/react-transition-group/-/react-transition-group-4.4.2.tgz", "resolved": "https://registry.npmjs.org/react-transition-group/-/react-transition-group-4.4.2.tgz",
@@ -27506,9 +27515,9 @@
} }
}, },
"dotenv": { "dotenv": {
"version": "8.2.0", "version": "10.0.0",
"resolved": "https://registry.npmjs.org/dotenv/-/dotenv-8.2.0.tgz", "resolved": "https://registry.npmjs.org/dotenv/-/dotenv-10.0.0.tgz",
"integrity": "sha512-8sJ78ElpbDJBHNeBzUbUVLsqKdccaa/BXF1uPTw3GrvQTBgrQrtObr2mUrE38vzYd8cEv+m/JBfDLioYcfXoaw==" "integrity": "sha512-rlBi9d8jpv9Sf1klPjNfFAuWDjKLwTIJJ/VxtoTwIR6hnZxcEOQCZg2oIL3MWBYw5GpUDKOEnND7LXTbIpQ03Q=="
}, },
"dotenv-expand": { "dotenv-expand": {
"version": "5.1.0", "version": "5.1.0",
@@ -35187,6 +35196,13 @@
"webpack-dev-server": "3.11.1", "webpack-dev-server": "3.11.1",
"webpack-manifest-plugin": "2.2.0", "webpack-manifest-plugin": "2.2.0",
"workbox-webpack-plugin": "5.1.4" "workbox-webpack-plugin": "5.1.4"
},
"dependencies": {
"dotenv": {
"version": "8.2.0",
"resolved": "https://registry.npmjs.org/dotenv/-/dotenv-8.2.0.tgz",
"integrity": "sha512-8sJ78ElpbDJBHNeBzUbUVLsqKdccaa/BXF1uPTw3GrvQTBgrQrtObr2mUrE38vzYd8cEv+m/JBfDLioYcfXoaw=="
}
} }
}, },
"react-transition-group": { "react-transition-group": {
+1
View File
@@ -9,6 +9,7 @@
"axios": "^0.22.0", "axios": "^0.22.0",
"bootstrap": "^5.1.1", "bootstrap": "^5.1.1",
"bootstrap-icons": "^1.5.0", "bootstrap-icons": "^1.5.0",
"dotenv": "^10.0.0",
"formik": "^2.2.9", "formik": "^2.2.9",
"gsap": "^3.8.0", "gsap": "^3.8.0",
"ol": "^6.8.1", "ol": "^6.8.1",
+2 -2
View File
@@ -1,6 +1,6 @@
import { createContext } from "react"; import { createContext } from "react";
import { APIClient } from "./utils/APIClient"; import { APIClient } from "./utils/APIClient";
require('dotenv').config();
export const BACKEND_URL = "http://localhost:5000"; export const BACKEND_URL = "http://localhost:5000";
export const EVENT_CONTEXT = createContext(); export const EVENT_CONTEXT = createContext();
export const API_CLIENT = new APIClient(BACKEND_URL); export const API_CLIENT = new APIClient(process.env.DEPLOY ? "/" : BACKEND_URL);
+6 -2
View File
@@ -6,6 +6,10 @@ const eventSchema = new schema({
type: String, type: String,
required: true, required: true,
}, },
adress: {
type: String,
required: false,
},
created:{ created:{
time:{ time:{
type:Number, type:Number,
@@ -22,11 +26,11 @@ const eventSchema = new schema({
}, },
lat: { lat: {
type: Number, type: Number,
required: true, required: false,
}, },
lon: { lon: {
type: Number, type: Number,
required: true, required: false,
}, },
}); });