fogoplayer

@fogoplayer@mastodon.world

This profile is from a federated server and may be incomplete. Browse more on the original instance.

ernie, to random
@ernie@writing.exchange avatar

At some point folks are going to move towards self-hosting just because of how wasteful the cloud is.

https://werd.social/@ben/112315158111380780

fogoplayer,

@ernie what makes self-hosted less wasteful? Don't the same number of bits have to be flipped either way?

joe, to javascript

In last week’s post, I said, “That is because you can not pass an array directly into a web component”. I said that I might take a moment at some point to talk about how you could do that. Well, today is the day we are doing that.

Let’s start with a basic Lit example.

See the Pen by Joe Steinbring (@steinbring)
on CodePen.

You will notice that the ArrayList class has an items property that is an array type. Lit won’t let you do something like <array-list items = ['Item 1', 'Item 2', 'Item 3']></array-list> but it is fine with you passing it in using javascript. That means that myList.items = ['Item 1', 'Item 2', 'Item 3']; does the job, fine.

So, how can we do that with a Vue.js array?

See the Pen by Joe Steinbring (@steinbring)
on CodePen.

It is the same thing except you need to set the value of the list in an onMounted() lifecycle hook.

What about if we want to do it with React?

See the Pen by Joe Steinbring (@steinbring)
on CodePen.

With React, you just set the value in a useEffect() React hook.

https://jws.news/2024/how-to-pass-an-array-as-a-property-into-a-web-component/

fogoplayer,

@joe did you know you can do it if you're passing from one lit component to another?

ernie, to random
@ernie@writing.exchange avatar

Reading Daring Fireball today sure is something. Appreciate Gruber’s perspective, but he is clearly rooting for the home team.

fogoplayer,

@ernie What's the airport lounge metaphor? A Google search gave me a bunch of people named Gruber tweeting about flying first-class

stephaniewalter, to random
@stephaniewalter@front-end.social avatar

Is bread kneading NSFW? According to this TensorFlow client side indecent content checking tool, it is.
And this is why, you need manual check.
If you want to play with NSFWJS: https://nsfwjs.com/

fogoplayer,

@stephaniewalter a couple months ago I had to wait until I got home to install a new to-do list app because it had gotten flagged by the content system at school

fogoplayer,

@stephaniewalter I'm not sure... I just know it had come recommended to me, so one day between classes I went to the website to install it and was greeted by a message that I couldn't access the website due to its pornographic content.

I ended up using a hotspot... it all looked fine to me

chicgeek, to uk
fogoplayer,

@chicgeek @katiefenn would love to see this packaged as a web component for use on other sites

Really just anything to spread it beyond this one domain

fogoplayer, to NewOrleans
fogoplayer,

@BeAware I can't speak for everyone, but personally: I knew about the LA purchase. I did not know that Spain owned LA a month before America bought it from France.

It became more believable after I learned that it was supposed to be only a one day difference: France had been unofficially ruling LA for a while, and the transfer from Spain to France was just a formality so the sale could go through.

thisismissem, to mastodon
@thisismissem@hachyderm.io avatar

Challenge for a UX designer: rethink the UI/UX around content warnings on the Fediverse (mastodon, pixelfed, etc) to allow capturing not just a text field, but also some predefined labels (e.g., 18+, sexual imagery, violent imagery, etc)

Technically these labels would come from "providers" which define what they mean and controls that should be implemented.

#mastodon #Pixelfed #UX #uxdesign #fediverse

fogoplayer,

@thisismissem @smallcircles perhaps allow/normalize hashtags in CWs?

Benefits:

  • reuses functionality (Don't need to build a labeling IRI system & UI)
  • already know how hashtags affect into character counts
  • allows free form input while consolidating on a few standard ones
  • selecting a label from a list requires a manageable number of labels

The main con as I see it is relying on recall rather than that recognition (users can't see the list of all potential hashtags)

scottjenson, to Amazon
@scottjenson@social.coop avatar

I just got 'the upgrade note' from #amazon video telling me to pay $3/month or face ads. If they had just raised the price of Prime, I'd likely just have gone with it. But this.... blackmail just feels so wrong and makes me feel powerless. I want to yell "hell no!" just on principle.

I know, this is childish, but in their greed to optimize the conversion funnel, they've destroyed their #brand and I feel like a #UX experiment. It feels dirty and I want nothing to do with it.

fogoplayer,

@scottjenson I canceled my Netflix subscription the day I signed up for it. I thought it was a little dystopian that they hid the tier I wanted behind a dark pattern to try to get me to pay for a more expensive one.

I was disgusted when they then prompted me to upgrade on my second time opening the app—before I had watched a single piece of content

fogoplayer, to random

@dancinyogi I've been wondering—is there a link between your interests in the #SWFLEagleCam and the #PhiledelphiaEagles?

frameworkcomputer, to random
@frameworkcomputer@fosstodon.org avatar
fogoplayer,

@frameworkcomputer as a Chromebook power user, I'm really intrigued by the framework Chromebook edition because it gives you power no other model can match. 64gb of RAM in a Chromebook is a pretty epic selling point. Thanks for making it!

imyke, to random
@imyke@myke.social avatar
fogoplayer,

@TerabyteTiger I don't get the meme?

cjerrington, to javascript
@cjerrington@mstdn.social avatar

Oh, #JavaScript ... why don't you like equal operands?

One would think the following would be the same

if site.env = 'dev'

if site.env === 'dev'

fogoplayer,

@cjerrington @davesh it's actually even more complicated:

= assignment
== equality with type conversion
!= inequality with type conversion
=== strict equality
!== strict inequality

Hope that helps in the future!

Gargron, to random
@Gargron@mastodon.social avatar

My life is so dominated by discussions of how Mastodon can be improved that it's really refreshing to hear about what people like. Thanks @dangillmor!

fogoplayer,

@Gargron @dangillmor I was just thinking the other day about how awesome the chronological feed is and how I take it for granted

brawaru, (edited ) to javascript
@brawaru@mstdn.social avatar

developers, do you think should be a part of the build process?

I've seen quite a few projects use and plugins to run ESLint during their build process. This both shows a huge error overlay when there are linting errors, and halts the build when building for production.

However, I never understood that, as linting does not really ensure validity of the code, but rather that it aligns to some stylistic rules.

What do y'all think about this?

fogoplayer,

@brawaru I vote yes, only because it doesn't make sense to use it halfway. If your team doesn't want to use a linter or a formatter, it doesn't need to be a part of your build process. But if you find any value in it, my experience is that nobody (including me 😅) cares about linter errors unless they're tied to something they want (like deployment)

fogoplayer, to Futurology

I'm working on a #research project at school where I'm developing a #JS library, and I'm looking for some feedback on my API.

If you have a second to skim through my docs and point out anything that feels clunky or suggest improvments, I would really appreciate it!

(Boosts welcome)

https://zarinloosli.com/space-bridge/

#javascript #frontend #typescript

fogoplayer,

@aral thank you!

mattgrayyes, to random
@mattgrayyes@chaos.social avatar

Wow we’ve got our first episode of Citation Needed that’s about to hit 1 million views!

https://youtu.be/6TsEGt841pw

video/mp4

fogoplayer,

@mattgrayyes congrats! I absolutely love this show!

fogoplayer, to Unions

What if #laborday functioned like a Jewish day of jubilee and any #unions that are still negotiating automatically get all of their demands met

#amptp #sagaftra #writersstrike #strike

b0rk, (edited ) to random
@b0rk@jvns.ca avatar

some people who make programming easier

(who am I missing?)

fogoplayer,

@b0rk tag yourself

nurkiewicz, to javascript
@nurkiewicz@fosstodon.org avatar

Useful #JavaScript library to limit the number of concurrently running promises:

import pLimit from 'p-limit';

const limit = pLimit(2);  
await Promise.all([  
 limit(() =&gt; fetch('/foo')),  
 limit(() =&gt; fetch('/bar')),  
 limit(() =&gt; fetch('/bzz'))  
]);  

In the above code only two fetch requests will run at the same time. The third will start only when one of the first two complete

fogoplayer,

@nurkiewicz what's an example of a situation where you might need this? I generally try to make my fetch requests as concurrent as possible

fogoplayer,

@nurkiewicz Gotcha! I was worried there was some massive inherent performance penalty I had missed

JosephMenn, to random

When they want a story about a Musk tweet.

fogoplayer,

@JosephMenn Love the image! Where did you find it?

tomscott, to random

I don't really use this, but I'm registering an account anyway, just in case this turns out to be the next big thing.

fogoplayer,

@dragfyre @tomscott I'm too chicken to tag his friend Matt Gray on this, who IS active on fedi

  • All
  • Subscribed
  • Moderated
  • Favorites
  • JUstTest
  • ngwrru68w68
  • everett
  • InstantRegret
  • magazineikmin
  • thenastyranch
  • rosin
  • Durango
  • ethstaker
  • Youngstown
  • slotface
  • khanakhh
  • kavyap
  • DreamBathrooms
  • Leos
  • osvaldo12
  • tacticalgear
  • cubers
  • cisconetworking
  • anitta
  • provamag3
  • modclub
  • mdbf
  • GTA5RPClips
  • tester
  • megavids
  • normalnudes
  • lostlight
  • All magazines