Skip to main content

Prerequisites

Before installing node-fullykiosk, ensure you have:
  • React 18.0+ installed in your project
  • Fully Kiosk Browser installed on your target Android device
  • Node.js 16+ for package management
The library uses React Hooks, so you need React 16.8 or higher. However, it’s developed with React 18.2.0, so we recommend using React 18+ for the best experience.

Install the Package

Install node-fullykiosk using your preferred package manager:
npm install fullykiosk
The package is published on npm as fullykiosk, not node-fullykiosk.

TypeScript Setup

The library is written in TypeScript and includes type definitions out of the box. No additional @types packages are needed. All hooks are fully typed, including:
  • Return values with proper type inference
  • Event handler types
  • Enum types for states (e.g., PlugStates for charging)
import { useBatteryLevel, useCharging } from 'fullykiosk';
import type { PlugStates } from 'fullykiosk';

function BatteryStatus() {
  const { batteryLevel } = useBatteryLevel();
  const { charging, chargeState } = useCharging();
  
  // batteryLevel: number | undefined
  // charging: boolean | undefined
  // chargeState: PlugStates | undefined
}

Verification

After installation, verify the setup by importing a hook:
1

Import a hook

Create a test component that imports one of the hooks:
import { useDeviceName } from 'fullykiosk';

function DeviceInfo() {
  const deviceName = useDeviceName();
  return <div>Device: {deviceName ?? 'Not in Fully Kiosk'}</div>;
}
2

Build your application

Ensure your application builds without errors:
npm run build
3

Test in Fully Kiosk Browser

Deploy your application and open it in Fully Kiosk Browser on an Android device. The hooks should return actual device data instead of undefined.
Hooks will return undefined when not running in Fully Kiosk Browser. This is by design and allows you to develop and test in a regular browser. Always check for undefined values in your components.

Development Environment

For local development, the hooks will safely return undefined when the Fully Kiosk API is not available. This allows you to:
  • Develop your application in Chrome or other browsers
  • Use React DevTools and other development utilities
  • Test your UI with mock data or fallback states
import { useBatteryLevel } from 'fullykiosk';

function BatteryWidget() {
  const { batteryLevel } = useBatteryLevel();
  
  // Handle undefined for development
  if (batteryLevel === undefined) {
    return <div>Battery info not available (not in Fully Kiosk)</div>;
  }
  
  return <div>Battery: {batteryLevel}%</div>;
}

What’s Included

The package includes:
  • All React Hook exports
  • TypeScript type definitions
  • CommonJS build for Node.js compatibility
The library has:
  • Zero runtime dependencies (only peer dependency on React)
  • Small bundle size - optimized for kiosk applications
  • Tree-shakeable exports - import only the hooks you need

Next Steps

Quickstart Guide

Build your first kiosk application with node-fullykiosk

Build docs developers (and LLMs) love