Toggle navigation
Toggle navigation
This project
Loading...
Sign in
fe
/
yohobuywap-node
·
Commits
Go to a project
GitLab
Go to group
Project
Activity
Files
Commits
Pipelines
0
Builds
0
Graphs
Milestones
Issues
0
Merge Requests
0
Members
Labels
Wiki
Forks
Network
Create a new issue
Download as
Email Patches
Plain Diff
Browse Files
Authored by
郭成尧
2018-02-27 17:48:27 +0800
Commit
34fdb6d8b22a983039ca0bd4b3fee4cb8dce842a
1 parent
88f86a27
postMessage
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
0 deletions
public/js/activity/miniprogram/index.js
public/js/activity/miniprogram/post-message.js
public/js/activity/miniprogram/index.js
View file @
34fdb6d
require
(
'./link-handle'
);
require
(
'./post-message'
);
...
...
public/js/activity/miniprogram/post-message.js
0 → 100644
View file @
34fdb6d
/* global wx */
/**
* 向小程序发消息
*/
class
PostMessage
{
constructor
()
{
if
(
wx
)
{
wx
.
miniProgram
.
postMessage
({
data
:
{
title
:
document
.
title
}
});
}
else
{
console
.
error
(
'no wx object'
);
}
}
}
export
default
new
PostMessage
();
...
...
Please
register
or
login
to post a comment