Go Time: Golang, Software Engineering cover image

Reflection and meta programming

Go Time: Golang, Software Engineering

CHAPTER

How to Write a JSON Package That Doesn't Use Reflect

I wrote a little, it's not finished. It's basically a fake JSON data generator. So you pass in any data. I decode into structs most of the time. Well, if you're writing anything where you don't know the data structure, some APIs do do that. And so in that sort of case, yeah, we would want people to be able to pass in any kind of API hosted on a website,. including an array of objects as well as a single object. That was the idea.

00:00
Transcript
Play full episode

Remember Everything You Learn from Podcasts

Save insights instantly, chat with episodes, and build lasting knowledge - all powered by AI.
App store bannerPlay store banner