Lemmy: Bestiverse
  • Communities
  • Create Post
  • Create Community
  • heart
    Support Lemmy
  • search
    Search
  • Login
  • Sign Up
RSS BotMB to Lobste.rsEnglish · 4 months ago

Reflecting on deserialization. Why you should explicitly decode your JSON

hashset.dev

external-link
message-square
0
link
fedilink
1
external-link

Reflecting on deserialization. Why you should explicitly decode your JSON

hashset.dev

RSS BotMB to Lobste.rsEnglish · 4 months ago
message-square
0
link
fedilink
Reflecting on deserialization. Why you should explicitly decode your JSON.
hashset.dev
external-link
When working with JSON, 99% of the time developers write a custom type that closely matches the format of the JSON payload, and then use their favorite programming languages built in metaprogramming ability to automatically deserialization the payload into a typed object. I want to tell you why you shouldn't use reflection and instead take a page out of functional programming and explicitly decode the JSON payload.

Comments

alert-triangle
You must log in or # to comment.

Lobste.rs

lobsters

Subscribe from Remote Instance

You are not logged in. However you can subscribe from another Fediverse account, for example Lemmy or Mastodon. To do this, paste the following into the search field of your instance: !lobsters@lemmy.bestiver.se
lock
Community locked: only moderators can create posts. You can still comment on posts.

RSS Feed of lobste.rs

Source of the RSS Bot

Visibility: Public
globe

This community can be federated to other instances and be posted/commented in by their users.

  • 20 users / day
  • 128 users / week
  • 370 users / month
  • 1.67K users / 6 months
  • 2 local subscribers
  • 395 subscribers
  • 15.5K Posts
  • 1.07K Comments
  • Modlog
  • mods:
  • patrick
  • RSS Bot
  • BE: 0.19.15
  • Modlog
  • Instances
  • Docs
  • Code
  • join-lemmy.org