gglukmann / use-google-sheets

📝 A React Hook for getting data from Google Sheets API v4

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Links in field values

spacebeers opened this issue · comments

Hello. I've been using this hook for an app I'm building that uses a Google Sheet as the data source. It's been great to use and super easy to set up (specially compared to a lot of the other options out there) but I've got an issue where a column I need to view has a link in the data.

Screenshot 2023-03-17 at 08 57 18

This is just returning as a flat string value like "TRK-FORD-13-433" rather than the actual contents of the cell I was expecting.

If I'm just not doing something correctly then please let me know, otherwise is there a way around this?

Thanks

Hi, right now you can't get formatted values, only strings. So this is working as expected right now. Getting formatted values is possible, but this needs additional development for this library because formatted values have really complex object structure. Documentation can be found here https://developers.google.com/sheets/api/reference/rest/v4/spreadsheets.values

Thanks for the reply. I'll have a look at the Google APIs which I was really trying to avoid.