Blog

Page 217 of my articles, tutorials, and thoughts

Latest Articles

Cover Image for Pretty-Print JSON in Java
javajsonpretty-print

Pretty-Print JSON in Java

Published on September 2, 2023

# Pretty-Print JSON in Java like a Pro! šŸ˜Ž Do you ever find yourself in a situation where you need to make your JSON data more human-readable? Don't worry, you're not alone! šŸ˜… In this blog post, we'll explore how to pretty-print JSON in Java, even if you

Cover Image for Decoding JSON using json.Unmarshal vs json.NewDecoder.Decode
json

Decoding JSON using json.Unmarshal vs json.NewDecoder.Decode

Published on September 2, 2023

# Decoding JSON using `json.Unmarshal` vs `json.NewDecoder.Decode` šŸ‘‹ Hey there! Are you developing an API client and struggling with encoding and decoding JSON payloads? Don't worry, I've got you covered! In this blog post, we'll explore two popular meth

Cover Image for How to test if a string is JSON or not?
javascriptjsonmysql

How to test if a string is JSON or not?

Published on September 2, 2023

# How to Test if a String is JSON or Not? So you have a problem. You're making an AJAX call to your server, and it could potentially return two different types of data: a JSON string with useful information, or an error message string generated by the `my

Cover Image for Why is it a bad practice to return generated HTML instead of JSON? Or is it?
ajaxhtmljavascriptjqueryjson

Why is it a bad practice to return generated HTML instead of JSON? Or is it?

Published on September 2, 2023

# Is it a bad practice to return generated HTML instead of JSON? Or is it? šŸ“œ It is quite common to load HTML content from custom URLs/Web services using frameworks like JQuery. This approach has been proven to provide satisfactory performance in many cas

Cover Image for Write / add data in JSON file using Node.js
javascriptjsonnode.js

Write / add data in JSON file using Node.js

Published on September 2, 2023

# How to Write and Add Data in a JSON File using Node.js Are you struggling to write and add data to a JSON file using Node.js? Look no further! In this guide, we will walk you through a step-by-step process to help you achieve your goal. šŸ“šŸ’» ## The Pro

Cover Image for How can I convert JSON to CSV?
csvjsonpython

How can I convert JSON to CSV?

Published on September 2, 2023

# How to Convert JSON to CSV: A Step-by-Step Guide šŸ“ˆ Are you facing the challenge of converting a JSON file to a CSV file? Don't worry, we've got you covered with an easy solution in Python! šŸ In this guide, we'll walk you through the process and addres

Cover Image for How to save the output of a console.log(object) to a file?
javascriptjson

How to save the output of a console.log(object) to a file?

Published on September 2, 2023

# How to Save the Output of a console.log(object) to a File? šŸ˜®šŸ’¾ So you've got a massive, complex object that you want to save from your console.log? We feel your pain. Luckily, we've got some useful solutions to help you out! šŸ‘āœØ ## The Challenge šŸ¤” W

Cover Image for How can I return camelCase JSON serialized by JSON.NET from ASP.NET MVC controller methods?
json

How can I return camelCase JSON serialized by JSON.NET from ASP.NET MVC controller methods?

Published on September 2, 2023

## 🐫 Returning camelCase JSON serialized by JSON.NET from ASP.NET MVC controller methods If you're using ASP.NET MVC and want to return JSON data in camelCase format rather than the default PascalCase, this guide will help you solve this problem using JS

Cover Image for Adding elements to object
javascriptjsonobject

Adding elements to object

Published on September 2, 2023

# Adding Elements to an Object: Simplified Guide šŸ˜Ž Ever found yourself in a situation where you need to add elements to an existing object? Don't worry, we've got your back! In this guide, we'll walk you through common issues and provide easy solutions t

Cover Image for How to get object length
javascriptjsonobject

How to get object length

Published on September 2, 2023

# How to Get Object Length: A Simple Guide šŸ“ Have you ever found yourself wondering how to determine the length of an object in JavaScript? šŸ¤” You're not alone! Understanding how to obtain the length of an object can be puzzling, especially when built-in