1.0.1 • Published 7 years ago

vue-wechat-share v1.0.1

Weekly downloads
13
License
-
Repository
github
Last release
7 years ago

vue-wechat-share

A wechat social share component for VueJs

Usage

npm install vue-wechat-share -S

How to use?

You can import the whole package or each module individual.

import VueWeChatShare from 'vue-wechat-share'
Vue.use(VueWeChatShare)

Methods

  • $reqSignByUrl(url,cb):initializing URL,if null or "",there will a default value(window.location.href)
ParamsTypeRequireDesc
urlStringNosigned url
cbmethodYesThe callback through the current URL to get the signature information
  • $initWXConfig(signObj,isDebug):initialize weChat sdk to share the required configuration items
ParamsTypeRequireDesc
signObjObjectYesThis object contains four attributes(appId、timestamp、nonceStr、signature)
isDebugBooleanNoWhether to open debug debugging
  • $shareWeChat(shareParams):Share to weChat, the circle of friends, QQ and micro-blog platform
ParamsTypeRequireDesc
shareParamsObjectYesThis object contains four attributes(title、link、image、abstract)
1.0.1

7 years ago

1.0.0

7 years ago