Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

환경 변수를 통한 API 및 웹 서버 URL 관리 #142

Merged
merged 1 commit into from
Nov 14, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion frontend/src/components/EditorView.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -22,15 +22,15 @@

const ydoc = useMemo(() => {
return new Y.Doc();
}, [currentPage]);

Check warning on line 25 in frontend/src/components/EditorView.tsx

View workflow job for this annotation

GitHub Actions / frontend-lint

React Hook useMemo has an unnecessary dependency: 'currentPage'. Either exclude it or remove the dependency array

const provider = useMemo(() => {
return new WebsocketProvider(
"ws://localhost:1234",
import.meta.env.VITE_WS_URL,
`document-${currentPage}`,
ydoc,
);
}, [currentPage]);

Check warning on line 33 in frontend/src/components/EditorView.tsx

View workflow job for this annotation

GitHub Actions / frontend-lint

React Hook useMemo has a missing dependency: 'ydoc'. Either include it or remove the dependency array

const pageTitle = page?.title ?? "제목없음";
const pageContent = page?.content ?? {};
Expand Down
2 changes: 1 addition & 1 deletion frontend/src/components/canvas/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
useEffect(() => {
const doc = new Y.Doc();
const wsProvider = new WebsocketProvider(
"ws://localhost:1234",
import.meta.env.VITE_WS_URL,
"flow-room",
doc,
);
Expand Down Expand Up @@ -88,7 +88,7 @@
wsProvider.destroy();
doc.destroy();
};
}, [queryClient]);

Check warning on line 91 in frontend/src/components/canvas/index.tsx

View workflow job for this annotation

GitHub Actions / frontend-lint

React Hook useEffect has missing dependencies: 'setEdges' and 'setNodes'. Either include them or remove the dependency array

useEffect(() => {
if (!pages || !ydoc.current) return;
Expand Down
Loading