natjs / nat-explorer Goto Github PK
View Code? Open in Web Editor NEWAn example project using Nat & Weex.
An example project using Nat & Weex.
I use Weex to develop app, so far weex is very fast compared to cordova/nativescript/RN (some cases) but unfortunately Weex accesses to native API is difficult. Nat is out of date.
Please upgrade to support latest weex version. Thanks a lot. God bless you
我想做一个考勤拍照的功能,想在点考勤的时候拍摄考勤人员的照片,所以想能实时看到预览的人员图像,应该怎么用natjs的组件呢,能提供个思路吗?
Error:(37, 13) Failed to resolve: com.nat:media-video:1.1.3
你好,请问这个是否切换了位置了还是怎样呢??
There is no callback that 'onRequestPermissionsResult' in Camera
Get location 都没有问题。
Watch location 就会报错:
[ERROR]TIMES:1
{"message":"LOCATION_TIMEOUT","code":160080}
二维码和条码识别功能还是很常用的,希望能够完善到整个应用中!
Hi guys.
Thank you very much for this awesome project. It helped me understand and use weex in so many levels.
Is there a way you could also create a contacts plugin that would allow us to list/add/delete contacts across platforms? This is the only feature I need to start working on our app.
Cheers,
envomer
按照官方的引导
npm install natjs --save
weexpack plugin add nat-media-audio
然后执行
Nat.audio.play('http://cdn.instapp.io/nat/samples/audio.mp3')
保持
定位到 weex.requireModule('nat/media/audio') 返回的是undefined
起因是我使用natjs调用摄像头会闪退,以及页面无法跳转。而nat-explorer下载的没有问题。我创建的工程如下:
weexpack create xxx
// 安装配置使用最新的weex、babel-stage-0以及没有使用vue-router
cd xxx
npm install
npm install natjs --save
npm install less less-loader pug --save-dev
weexpack platform add android
weexpack plugin add xxx-camear xxx-image xxx-modal
在AndroidManifest.xml
添加
<activity
android:name="com.weex.app.WXPageActivity"
android:label="@string/app_name"
android:screenOrientation="portrait">
<intent-filter>
<action android:name="android.intent.action.VIEW"/>
<action android:name="com.weex.app.protocol.openurl"/>
<category android:name="android.intent.category.DEFAULT"/>
<category android:name="com.taobao.android.intent.category.WEEX"/>
<data android:scheme="http"/>
<data android:scheme="https"/>
<data android:scheme="file"/>
</intent-filter>
</activity>
然后把nat-explorer
源码内src
目录下拷贝过来一份
npm run android
成功安装app,首页也没有问题。问题在于无法点击进去子页面。
nat.toast
点击路径,是和nat-explorer
一致的。na-explorer/src/views/camera.vue
。这个时候应用闪退。weex文档实在太少,希望作者解答。
之后,我下载了nat-explorer
源码,然后npm install & npm run android
。这个是没有问题的。
和下载的app一样。
请问这两个还有什么细节上实现差异吗?
请问调用原生硬件(如相机)的module代码在哪里
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.