微信小程序分享小程序码的生成(带参数)以及参数的获取
if (options.scene) {
let scene=decodeURIComponent(options.scene);
let id=scene.split("&")[1];
that.setData({
sid: id,
});
that.getInfo(options);//读取详细
}
}
显示的内容为空
在微信小程序中,可以使用 onLoad 方法来获取小程序码的参数,并进行相应的处理。