Skip to content
This repository was archived by the owner on Jan 17, 2026. It is now read-only.

parthbhinde/react-native-local-only-hotspot

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

react-native-local-only-hotspot

This is a react native module to start a local-only hotspot on android devices running android 8 and above

Getting started

$ npm install react-native-local-only-hotspot --save

// Following permissions should be added in AndroidManifest.xml
    <uses-permission android:name="android.permission.CHANGE_WIFI_STATE"/>
    <uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION"/>
    <uses-permission android:name="android.permission.ACCESS_WIFI_STATE"/>

// Location permission should also be taken from user at runtime
// make sure to check for user's Android API,
// and not starting hotspot again when hotspot is already started.

Usage

import LocalOnlyHotspot from 'react-native-local-only-hotspot';

// To start the local-only-hotspot
LocalOnlyHotspot.start(onSuccess,onFailure)
//onSuccess we get a jsonobject with ssid and secret
LocalOnlyHotspot.stop(onStop)
//onStop we get a sting 'Stopped'
LocalOnlyHotspot.getConfig(onData)
//onData we get a jsonobject with ssid and secret

Refer to example.js for sample code

About

A react native module to start a local-only hotspot on android devices running android 8 and above

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors