Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

269
Views
null is not an object (evaluating 'this._nativeModule.isBluetoothEnabled') in react native

I've recently started to work on react native, I'm trying to integrate react-native-bluetooth-classic to my project. https://kenjdavidson.com/react-native-bluetooth-classic/api-overview/

However, I'm stuck on this error:

"TypeError: null is not an object (evaluating 'this._nativeModule.isBluetoothEnabled')

This error is located at: in Untitled (created by ExpoRoot) in ExpoRoot in RCTView (created by View) in View (created by AppContainer) in RCTView (created by View) in View (created by AppContainer) in AppContainer"

I have installed the component with

yarn add react-native-bluetooth-classic --save and

npx pod-install
The linking seems fine. I'm copying this example from the library https://github.com/kenjdavidson/react-native-bluetooth-classic-apps/blob/1cba89aaa1181998dbcab7a9549a88a9bb5071a1/BluetoothClassicExample/App.js#L57. However, is a class component and I would like use function component (so maybe it's that the problem) Inside my useeffect

  useEffect(() => {
  let enabled  = RNBluetoothClassic.isBluetoothEnabled();

My RNBluetoothClassic object is NULL and it gave me this error

TypeError: null is not an object (evaluating 'this._nativeModule.isBluetoothEnabled')

from my understanding it should have created it with the import

import RNBluetoothClassic, { BluetoothEventType } from 'react-native-bluetooth-classic'; So I think is a linkage problem or maybe I can't call a class component.

Someone has any idea? note at the moment I'm trying to test on android

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!