blog.rayspock.comGo Slice Copying: What Really Happens Under the Hood?In Go, variables are passed by value, which means that when we pass variables as arguments to functions, Go makes a copy of those values for the function to use. However, the behaviour of Slice can be a bit confusing at first glance, especially if we...Sep 6, 2023·4 min read
blog.rayspock.comAI Technology Meets Social Media: The Discord Bot ProjectAs someone who's been using ChatGPT for a while now, I've been exploring how to maximise its benefits and integrate it into my daily life. I've been working on a side project to develop a Discord bot that interacts with ChatGPT, similar to the one pr...May 18, 2023·4 min read
blog.rayspock.comOne Thing You Might Overlook When Reading Response Body in GoThe Go net/http package provides a robust set of functionality to allow us to deal with HTTP requests and responses. However, reading the response body is a common task that requires a bit of caution. In this blog, we will explore the pitfall I exper...Apr 10, 2023·6 min read
blog.rayspock.comUnleashing the power of Go: How to Unmarshal Dynamic JSONToday we are going to write our own custom json.Unmarshal() method. I find it very useful and can make our code more maintainable and readable if we can make good use of type alias and the json.Unmarshal method. Let's say we want to decode a JSON-enc...Mar 5, 2023·5 min read
blog.rayspock.comTips on How to Speed Up Your WorkflowHave you ever tried to maintain services between environments and got lost in all the variables? Or even broken things by accident? Today I'm going to give you some tips on how to speed up your workflow and make things easier. My focus will be mainly...Feb 9, 2023·4 min read