Pebble App Framework: Phone API
    Preparing search index...

    Function readPebbleAppUnits

    • Reads the wearer's units from the Pebble app's built-in Preferences plugin, for a caller that has to tell the Pebble app's own units from the defaults, such as a settings page showing them.

      A read the Pebble app refuses answers no units and the reason, such as PERMISSION_DENIED, or NO_REASON when the refusal names none, and a reply that names none of the units answers no units and NO_UNITS. Only a reply that names them answers units, with the plugin's own choices over them and the defaults for any it leaves out.

      Parameters

      Returns Promise<{ error?: string; units: WeatherUnits | null }>

      The units, or null and the reason there are none.