Uploaded image for project: 'Realm JavaScript SDK'
  1. Realm JavaScript SDK
  2. RJS-2457

Create a meaningful error message when the `Realm` binary is not bound to the JS environment

    • Type: Icon: Task Task
    • Resolution: Fixed
    • Priority: Icon: Minor - P4 Minor - P4
    • None
    • Affects Version/s: None
    • Component/s: Node.js, React Native, WASM
    • None

      Currently when users of v12 end up in a state where Realm is not compiled/available in their environment (for example: for got to pod install or tried expo web or expo go), the error returned is:

      TypeError: Cannot read property 'Helpers_get_table' of undefined
      

      This is misleading and can lead to frustration, as it is very unclear what the issue actually is. We should create a check for this problem and respond with a meaningful error message such as:

      Realm could not be found in your environment.  Make sure you have followed the setup instructions at https://www.mongodb.com/docs/realm/sdk/react-native/install/
      

      We also could create a TROUBLESHOOTING.md which goes provides some general guidance specific to these type of errors. If this is done, than it should be linked in instead of the mdb installation docs.

            Assignee:
            Unassigned Unassigned
            Reporter:
            andrew.meyer@mongodb.com Andrew Meyer
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: