@@ -51,6 +51,44 @@ export const WorkspacePage: FC = () => {
51
51
cancellationError,
52
52
} = workspaceState . context
53
53
54
+ useEffect ( ( ) => {
55
+ // console.log("workspace updating in component", workspace)
56
+ // console.log("resources", resources)
57
+ } , [ workspace , resources ] )
58
+
59
+ // useEffect(() => {
60
+ // if (!workspace?.id) {
61
+ // return
62
+ // }
63
+ //
64
+ // console.log("hey im in here")
65
+ // const sse = new EventSource(
66
+ // `${location.protocol}//${location.host}/api/v2/workspaces/${workspace.id}/watch`,
67
+ // { withCredentials: true },
68
+ // )
69
+ //
70
+ // sse.onmessage = (e) => console.log("event", e)
71
+ //
72
+ // sse.addEventListener("ping", (event) => {
73
+ // console.log("ping event", event)
74
+ // })
75
+ //
76
+ // sse.addEventListener("data", (event) => {
77
+ // console.log("data event", event)
78
+ // })
79
+ //
80
+ // sse.onerror = (error) => {
81
+ // // error log here
82
+ // console.log("error", error)
83
+ //
84
+ // sse.close()
85
+ // }
86
+ //
87
+ // return () => {
88
+ // sse.close()
89
+ // }
90
+ // }, [workspace])
91
+
54
92
const canUpdateWorkspace = Boolean ( permissions ?. updateWorkspace )
55
93
56
94
const [ bannerState , bannerSend ] = useMachine ( workspaceScheduleBannerMachine )
0 commit comments