Skip to content

borie88/adonis-websocket-wechatmp

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

50 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Websocket Client for WeChat Mini Programs

This plugin is built for developers using Adonis JS with Websockets enabled on the backend and WeChat Mini Programs on the frontend.

You can use all client APIs available in the official browser client (docs here):

Adonis Websocket Client Docs

Setup

  1. Install the package
npm install adonis-websocket-wechatmp

You may freely use this NPM package in 3rd party frameworks like Taro, Wepy, MPVue, etc.

Vanilla Framework: NPM package install guide

  1. Then in your Mini Program project:

/pages/page/page.js

import Ws from 'adonis-websocket-wechatmp'
const ws = Ws('ws:// -or- wss://your-url-here')

Page({
  data: {},
  onLoad () {
      // init websocket connection
  }
})

About

Websocket client for AdonisJs framework.

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages

  • JavaScript 100.0%