Golang: Check if a Key Exists in a Map (If Contains)
Do you want to check if a key exists in a map? Golang has a very simple syntax for it. You can check or even… Read More »Golang: Check if a Key Exists in a Map (If Contains)
Do you want to check if a key exists in a map? Golang has a very simple syntax for it. You can check or even… Read More »Golang: Check if a Key Exists in a Map (If Contains)
If you want to work with a piece of string in Golang then your best friend is strings package! The split function can convert a… Read More »How to Split a String Into a Slice and Join Them Back [Golang]
Do you want to measure the execution time of a piece of code in Golang? Yes, there is a very simple solution using the Since… Read More »Golang: Easy Way to Measuring Execution Time (Elapsed Time)
If you are initiating a new slice and you know how many items you will put into it, then use the make() function: data :=… Read More »How to Improve Slice Performance in Go
If you need to iterate over a map in golang but you want to have only the keys or only the values then this snippet… Read More »Golang: Iterating Over Maps | Only Keys, Only Values, Both
Is there a chance to catch the termination (or interruption) signals and do some tasks before quitting the app in golang? YES! Just use this… Read More »Easy How to Catch Signals and Gracefully Shutdown in Golang!
I am using Passport for user authentication and I want to test the API with PHPUnit in Laravel. How can we have authenticated user? Laravel… Read More »Test API whith authenticate user when using Laravel Passport?
If you think the Faker class can help you in testing Laravel then add this line of code into your import section: Inside your class… Read More »How to import and use Faker in Laravel unit testing using PHPUnit
If you need to add some CSS style or Javascript file to your WordPress theme, the bad way is to put them directly in your… Read More »How to Properly Including JavaScripts and Styles in WordPress theme
If you created a new WordPress child theme from scratch and the parent style.css doesn’t load, the solution is here. Create or edit the functions.php file in… Read More »Enqueue stylesheet from parent to child WordPress theme