1

i have been creating a app with supabase and expo and before it worked correctly... but now it keeps getting this error...

TypeError: undefined is not an object (evaluating 'window.location.href')

at node_modules/react-native/Libraries/Core/ExceptionsManager.js:104:6 in reportException

at node_modules/react-native/Libraries/Core/ExceptionsManager.js:172:19 in handleException

at node_modules/react-native/Libraries/Core/setUpErrorHandling.js:24:6 in handleError

at node_modules/@react-native/polyfills/error-guard.js:49:36 in ErrorUtils.reportFatalError

at node_modules/metro-runtime/src/polyfills/require.js:204:6 in guardedLoadModule

at http://192.168.100.31:19000/node_modules/expo/AppEntry.bundle?platform=android&dev=true&hot=false&minify=false:122163:3 in global code

my code for database.js is:

import { createClient } from '@supabase/supabase-js'

const supabaseUrl = process.env.SUPABASE_APIURL

const supabaseKey = process.env.SUPABASE_KEY

export default supabase = createClient(supabaseUrl, supabaseKey)

1 Answer 1

1

I encoutered the same bug and created an issue for it on their gh repo. It should be fixed once they merge it and release it. https://github.com/supabase/supabase/issues/3790

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.