From 356d736f4eabe0ed7e44df1ca1a83bc743f6cd2d Mon Sep 17 00:00:00 2001 From: moonrailgun Date: Wed, 4 Mar 2020 14:50:47 +0800 Subject: [PATCH] Trans and docs for socketio feature --- README.md | 2 ++ components/realtime/socketio.vue | 2 +- lang/en-US.js | 2 ++ nuxt.config.js | 8 ++++---- pages/realtime.vue | 2 +- 5 files changed, 10 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index 02a2eafe3..b60f371bc 100644 --- a/README.md +++ b/README.md @@ -92,6 +92,8 @@ _Customized themes are synced with local session storage_ 📡 **Server Sent Events**: Receive a stream of updates from a server over a HTTP connection without resorting to polling. +🌩 **Socket.IO**: Send and Receive data with socketio server. SocketIO is popular websocket solution. + 🔮 **GraphQL**: GraphQL is a query language for APIs and a runtime for fulfilling those queries with your existing data. - Set endpoint and get schemas diff --git a/components/realtime/socketio.vue b/components/realtime/socketio.vue index 718e35f59..1bdf5bb5a 100644 --- a/components/realtime/socketio.vue +++ b/components/realtime/socketio.vue @@ -85,7 +85,7 @@ export default { }, data() { return { - url: "wss://echo.websocket.org", + url: "ws://", connectionState: false, io: null, communication: { diff --git a/lang/en-US.js b/lang/en-US.js index b123c8384..811b98210 100644 --- a/lang/en-US.js +++ b/lang/en-US.js @@ -274,4 +274,6 @@ export default { paste_a_note: "Paste a note", import_from_sync: "Import from Sync", notes: "Notes", + socketio: "Socket.IO", + event_name: "Event Name", } diff --git a/nuxt.config.js b/nuxt.config.js index 988b00f5b..685a3ca61 100644 --- a/nuxt.config.js +++ b/nuxt.config.js @@ -57,7 +57,7 @@ export default { { name: "keywords", content: - "postwoman, postwoman chrome, postwoman online, postwoman for mac, postwoman app, postwoman for windows, postwoman google chrome, postwoman chrome app, get postwoman, postwoman web, postwoman android, postwoman app for chrome, postwoman mobile app, postwoman web app, api, request, testing, tool, rest, websocket, sse, graphql", + "postwoman, postwoman chrome, postwoman online, postwoman for mac, postwoman app, postwoman for windows, postwoman google chrome, postwoman chrome app, get postwoman, postwoman web, postwoman android, postwoman app for chrome, postwoman mobile app, postwoman web app, api, request, testing, tool, rest, websocket, sse, graphql, socketio", }, { name: "X-UA-Compatible", @@ -353,14 +353,14 @@ export default { code: "ja", name: "日本語", iso: "ja-JP", - file: "ja-JP.js" + file: "ja-JP.js", }, { code: "ko", name: "한국어", iso: "ko-KR", - file: "ko-KR.js" - } + file: "ko-KR.js", + }, ], defaultLocale: "en", vueI18n: { diff --git a/pages/realtime.vue b/pages/realtime.vue index e53072ffc..82fdd77a9 100644 --- a/pages/realtime.vue +++ b/pages/realtime.vue @@ -112,7 +112,7 @@ - +