unboiled.info
  • Communities
  • Create Post
  • heart
    Support Lemmy
  • search
    Search
  • Login
  • Sign Up
bigboismith@lemmy.world to Programming Horror@programming.dev · 6 months ago

Found this beauty in one of my old projects from school

lemmy.world

message-square
9
link
fedilink
4

Found this beauty in one of my old projects from school

lemmy.world

bigboismith@lemmy.world to Programming Horror@programming.dev · 6 months ago
message-square
9
link
fedilink
alert-triangle
You must log in or register to comment.
  • Rin@lemm.ee
    link
    fedilink
    arrow-up
    2
    ·
    6 months ago

    Nested json 👽

    • PoolloverNathan@programming.dev
      link
      fedilink
      arrow-up
      1
      ·
      6 months ago

      Someone’s handed me nested base-64 encoded JSON before and to this day I am moderately annoyed at them.

  • Python@programming.dev
    link
    fedilink
    arrow-up
    2
    ·
    6 months ago

    smh, could have used the short form ()=>{ instead of function 😤

    • Deebster@programming.dev
      link
      fedilink
      English
      arrow-up
      2
      ·
      6 months ago

      I’ve been coding long enough that I still think of that as a fairly new thing in JS.

  • zygo_histo_morpheus@programming.dev
    link
    fedilink
    arrow-up
    1
    ·
    6 months ago

    Why settle on cammel case (“saveGame”) or upper cammel case (“SaveGame”) when you can have one of each?

  • GBU_28@lemm.ee
    link
    fedilink
    English
    arrow-up
    1
    ·
    6 months ago

    I WILL NOT USE ANOTHER LINE. I DON’T NEED IT

    • SpicyLizards@reddthat.com
      link
      fedilink
      arrow-up
      1
      ·
      6 months ago

      The best code has the fewest lines.

      • Hello Hotel@lemmy.world
        link
        fedilink
        English
        arrow-up
        1
        ·
        edit-2
        4 months ago

        This is just as easy to write, just as sloppy but hopefully way easier to read.

        Game.onload = (data)=>{
        let a = data;
        a = JSON.decode(a)["saveGame"][0];
        a = JSON.decode(a)["SaveGame"];
        return a;
        }
        
  • Kissaki@programming.dev
    link
    fedilink
    English
    arrow-up
    1
    ·
    6 months ago

    In German we say “doppelt hält besser”. Is there an English saying like that? “Twice is stronger/more stable/holds better.”

Programming Horror@programming.dev

programming_horror@programming.dev

Subscribe from Remote Instance

Create a post
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: !programming_horror@programming.dev

Welcome to Programming Horror!

This is a place to share strange or terrible code you come across.

For more general memes about programming there’s also Programmer Humor.

Looking for mods. If youre interested in moderating the community feel free to dm @Ategon@programming.dev

Rules

  • Keep content in english
  • No advertisements (this includes both code in advertisements and advertisement in posts)
  • No generated code (a person has to have made it)

Credits

  • Icon base made by Lorc under CC BY 3.0 with modifications to add a gradient
Visibility: Public
globe

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

  • 2 users / day
  • 2 users / week
  • 2 users / month
  • 40 users / 6 months
  • 1 local subscriber
  • 2.05K subscribers
  • 35 Posts
  • 275 Comments
  • Modlog
  • mods:
  • Vacant@programming.dev
  • UI: unknown version
  • BE: 0.19.11
  • Modlog
  • Instances
  • Docs
  • Code
  • join-lemmy.org