Here is my update on my way working to finish the alpha
version of the Telescope
mobile app.
Looking at the doc
Supabase
is amazing in doc. I have developed a good habit of taking a look at the doc before searching for any tutorial. And the doc provide details how we can start using Supabase
with different framework and some of them are very popular such as: React, Angular, etc.... The doc show you how to use supabase
for authentication which is a classic, popular use case when it come to mind when talking about integrate a server into your project. Mine use case this time is much more simpler which is to contain all the quotes from student-quotes.js
so as we can share and avoid duplicate information between our wep app and our mobile app.
Start working on the project
Since my use case is much more simpler I might not need to have to use all of the configuration option when creating the Supabase
client. This is when blogging become amazing. During 60% of the meeting our prof always try to press how important writing blog and be able to reach out with other developers. When working on the issue, I come a across a wonderful article where he tackle all the basic incompatible between react-native
and supabase
.
"Blog about it"
After reading such an amazing article. This sentence from my prof keep running through in my mind. Your struggle might become a treasure for whoever come after and be able to read about it. So here are some highlighted issues that I have been able to tackle
Working with .env for the very first time
Yes, this is my first time ever working with the .env file and it also a best practice I learn from the telescope
web team. Before I did read some guides on how to run Telescope
but did not bother dig into it and see what is actually in those files untill I have to do it myself. Like I said, after creating a habit of reading docs, I feel more pleasant to spend time with it than a feel short stackoverflow
answer which not gonna last in my mind more than a day after the problem has been solved. After reading the expo
doc on how to work with environment variables with expo. I have no hard time implemented it but then it coming to another problem where I would not be able to connect to the client.
Trouble connecting the supabase client in local development
For this matter, I have been able to reach out the Kelvin through Linkedin
to see if he have experienced the same thing but it seem he not be able to spot it out. Then after talking with peoples of the supasbase upstream to see if they have some idea on how I would be able to solve the problem but there is no luck. Then it come to my final option to search for stackoverflow
and Duke had sent me a link as he know I was having problem with connecting to supabase. The answer pointing out localhost
mean is not pointing to the real machine when interpreted through mobile device so in local development we will change localhost
to 10.0.2.2
and finally I had be able to connect to the supabase
client.
My PR
Top comments (0)