weexpack plugin add nat-device-volume
npm install natjs --save
Use in weex project (.vue
/.we
)
<script>
import Nat from 'natjs'
// get
Nat.volume.get((err, ret) => {
console.log(ret)
})
// set
Nat.video.set(0.5)
</script>
See the Nat Documentation for more details.