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

[WebSocketChannel2023] update example #186

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open

Conversation

elf-pavlik
Copy link
Member

use onclose and onmessage as property not method

use onclose and onmessage as property not method
@elf-pavlik elf-pavlik requested a review from acoburn August 3, 2023 02:19
@@ -423,7 +423,7 @@ <h3 property="schema:name">Subscription Example</h3>
<figure id="websocket-new" class="example listing" rel="schema:hasPart" resource="#websocket-new">
<p class="example-h"><span>Example</span>: Establishing a new WebSocket connection.</p>

<pre about="#websocket-new" property="schema:description" typeof="fabio:Script"><code>const ws = new WebSocket("wss://websocket.example/?auth=Ys3KiUq", "http://www.w3.org/ns/solid/notifications#WebSocketChannel2023");</code></pre>
<pre about="#websocket-new" property="schema:description" typeof="fabio:Script"><code>const ws = new WebSocket("wss://websocket.example/?auth=Ys3KiUq");</code></pre>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you please quick remind me why is this no longer necessary?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll double-check it. When I used it with channel type URI as the protocol it was resulting in some error. Simply removing it worked. BTW I think this is only used in a non-normative example, if we want the channel type to rely on it would need to be specified in a normative way.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants