Get foreground app bundle ID (app.front_bid)
Declaration
bid = app.front_bid()
Returns
- bid
String. The bundle ID of the foreground app.
Returns"com.apple.springboard"when no app is in the foreground but SpringBoard is already loaded.
Returns"com.apple.backboardd"when no app is in the foreground and SpringBoard has not yet started (early boot stage).
Description
- Get the bundle ID of the foreground app.
Example
local bid = app.front_bid()
sys.alert("Foreground app bundle ID: "..bid)
Note: uses non-chapter API sys.alert.