NuxtJS + Socket.io + https
我希望在NuxtJS [https://nuxtjs.org/]
中以Socket.io為傳送資料的方式,不過功力有限連Socket.io都沒搞定。發現NuxtJS官方其實有實例
[https://github.com/nuxt/nuxt.js/tree/master/examples/with-sockets]是在https中運作。
不過事情當然沒這麼簡單,官方上沒有什麼說明,我也只好當成NuxtJS一樣安裝。
$ npm install nodemon
這個例子用了nodemon作管理,我也直接照用好了
先安裝一下
$ npm run dev
啟動看一下