lrenelidan / native-hybrid-h5 Goto Github PK
View Code? Open in Web Editor NEW原生app混合H5开发
原生app混合H5开发
兼容 - ios系统keydown keyup事件不生效
解决方案://监听搜索
$("input#searchkey").on("input",function(){
var t_arry = $(this).val();
console.log(t_arry);
setTimeout(function () {
// 请求相关操作
}, 300);
});
APP端与H5交互问题
安卓低版本系统(Android6.0以下)不支持es6语法(let const等),不会报错提醒
IOS与H5交互,用JSBridge
setupWebViewJavascriptBridge(function (bridge) {
bridge.callHandler("getUserData", function (response) {
var _data = response; //getUserData是ios定义的方法,供JS调用
})
})
Android与H5交互,可直接相互调用方法,但JS调用原生APP需要定义一个公用的参数
var infodata = window.DataAnalysis.getAppInfo(); //DataAnalysis是安卓定义的公用的参数,getAppInfo是安卓的方法
infodata = JSON.parse(infodata);
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.