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

What is my error? TypeError: null is not an object #22

Description

@ved08

This is my code:

import ImgToBase64 from 'react-native-image-base64';
sendData = async (uri) => {
  ImgToBase64.getBase64String(uri)
      .then(base64String => {
        console.log(base64String)
      })
      .catch(err => console.log("Error Occured", err));
}

someFunction = async () => {
...function content...
this.sendData(result.uri) //here result.uri is the path to that image i.e file://...
}

With this, I am getting an error saying "TypeError: null is not an object".
Please solve my error
Thanks!

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions