I’m briefly back again! 😃 I want to post this to highlight some sort of event happening with my generator hub page, as well as how I was able to fix it.

So, pretty recently, my Generator Manager was suddenly entirely broken for a few days. The DevTools console threw these errors, and I was confused for a moment thinking it was me constantly editing the list code that it breaks the entire functionality of the generator hub page.

That is, until I recently quickly hatched a simple solution to fix it before going to update the generator statistics for this week. I replaced the use of let i to var i in some of the code of the HTML panel, and it worked fine again! (I’ve just learned the difference between them btw)

The reason it was left broken and wasn’t fixed immediately is that I just haven’t had time to fix it due to, as usual, the post-recovery business. (Although I might plan to go back to Perchance slowly and regenerate my spirits to release some new projects and stuff here on this community! 😄)

3 points

That’s… strange. Normally it’s the other way around, unless you are doing something unusual, since let has block scope, and var has function scope. Those error normally come from using var as the variable then get’s “hoisted” and so becomes visible before the variable is actually declared.

Anyway, good that you were able to figure it out.

permalink
report
reply
3 points

I think the Perchance engine has its own way to handle variable declarations, since it’s also having its own syntax for list coding, maybe that’s why.

permalink
report
parent
reply

Casual Perchance

!casual_perchance@lemmy.world

Create post

Casual Perchance

A nonspecific casual place for anything Perchance, including generator outputs, memes, prompts, casual discussion, advertising your generator, and anything else you wouldn’t post in the more technical Perchance Forum.

This is where to post Community Events.

Resources:


Rules:

  • friendly discussion only please.
  • No loli/shota/etc and mark as NSFW anything NSFW

Community stats

  • 26

    Monthly active users

  • 94

    Posts

  • 153

    Comments