Skip to content

Commit

Permalink
Merge pull request #2248 from stakwork/feature/update-socket-message
Browse files Browse the repository at this point in the history
feat: added message for socket connection
  • Loading branch information
Rassl authored Sep 27, 2024
2 parents 5bcb0f4 + a5b057a commit 53a0997
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions src/components/App/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -246,6 +246,20 @@ export const App = () => {

ws.onmessage = (event) => {
console.log('Message from server:', event.data)

Check warning on line 248 in src/components/App/index.tsx

View workflow job for this annotation

GitHub Actions / build

Unexpected console statement

let id = 'a'

id = '51998781'

const command = {
command: 'subscribe',
identifier: JSON.stringify({ channel: 'ProjectLogChannel', id }),
}

// Send the command as a JSON string
ws.send(JSON.stringify(command))

console.log('Subscription command sent:', command)

Check warning on line 262 in src/components/App/index.tsx

View workflow job for this annotation

GitHub Actions / build

Unexpected console statement
// Handle the message from the server here
}

Expand Down

0 comments on commit 53a0997

Please sign in to comment.