Brightness

Contents

The Brightness plugin let you control the display brightness of your device.

Requires Cordova plugin: cordova-plugin-brightness. For more info, please see the Brightness plugin docs.

https://github.com/mgcrea/cordova-plugin-brightness

Stuck on a Cordova issue?

Installation

Community Enterprise
ionic cordova plugin add cordova-plugin-brightness npm install @ionic-native/brightness
Ionic EE comes with fully supported and maintained plugins from the Ionic Team. Learn More   or   Contact Us
ionic enterprise register --key=YOURPRODUCTKEY npm install @ionic-enterprise/brightness

Supported Platforms

  • Android
  • iOS

Usage

import { Brightness } from '@ionic-native/brightness/ngx';

constructor(private brightness: Brightness) { }

...

let brightnessValue = 0.8;
this.brightness.setBrightness(brightnessValue);