diff --git a/fcm-client/src/App.js b/fcm-client/src/App.js
index b2450f0..7cfc479 100644
--- a/fcm-client/src/App.js
+++ b/fcm-client/src/App.js
@@ -5,6 +5,8 @@ import {fetchToken, onMessageListener} from './firebase'
function App() {
fetchToken();
+ test()
+
onMessageListener().then(payload => {
console.log(payload);
}).catch(err => console.log('failed: ', err));
@@ -30,3 +32,16 @@ function App() {
}
export default App;
+
+function test() {
+ console.log("test")
+
+ fetch("http://localhost:8080/v1/users/06666445-b110-48aa-bb7b-36a379e6ae05", {
+ method: "GET",
+ headers: {
+ "X-AUTHORizatioN": "testa"
+ }
+ })
+ .then((response) => response.json())
+ .then((data) => console.log(data))
+}
\ No newline at end of file
diff --git a/picture-upload.html b/picture-upload.html
new file mode 100644
index 0000000..b6b287a
--- /dev/null
+++ b/picture-upload.html
@@ -0,0 +1,64 @@
+
+
+
+
+
+
+ Document
+
+
+
+
+
+
+
+
+ Upload file to see url
+
+
+
+
+
\ No newline at end of file
diff --git a/script.js b/script.js
index 7d1a5d8..0437e88 100644
--- a/script.js
+++ b/script.js
@@ -1,7 +1,14 @@
let ws = null
-let wsAddress = "ws://localhost:"
let wsPort = 3000
+let wsAddress = "ws://localhost:"
+//let wsAddress = "wss://alpha-ws.clickandjoin.umbach.dev"
+
+let sseAddress = "http://127.0.0.1:3005/"
+//let sseAddress = "https://alpha-sse.clickandjoin.umbach.dev/"
+
+const sseEnabled = true
+const wssEnabled = true
window.onload = () => {
const msg = document.getElementById("msg")
@@ -41,12 +48,14 @@ window.onload = () => {
}
connectWS()
- //connectSSE()
+ connectSSE()
}
function connectSSE() {
- var source = new EventSource("http://127.0.0.1:3005/sse")
+ if (!sseEnabled) return
+ var source = new EventSource(sseAddress)
+
source.onmessage = (e) => {
console.log(e.data)
@@ -57,6 +66,8 @@ function connectSSE() {
}
function connectWS() {
+ if (!wssEnabled) return
+
ws = new WebSocket(wsAddress + wsPort + "/?auth=sMURqnQt-88Ko-SaWu-2GLr-K2iQECXDyONm")
ws.onopen = () => {