jonathan7luke

joined 3 months ago
[–] jonathan7luke@lemmy.ml 6 points 1 day ago

Howard refused but accepted another position with the mayor instead, insisting that he did not feel victimized by the incident. On the contrary, Howard felt that he had learned from the situation. "I used to think it would be great if we could all be colorblind; that's naïve, especially for a white person, because a white person [can] afford to be colorblind. They don't have to think about race every day. An African American does."

Wow; I was surprised to get to the first controversy and discover such a thoughtful and empathetic take on the topic.

[–] jonathan7luke@lemmy.ml 1 points 3 days ago (1 children)

If you're building a website, you'll probably want to stick to Javascript over Rust.

This MDN article does a pretty good job at introducing the concept of making network requests in Javascript: https://developer.mozilla.org/en-US/docs/Learn_web_development/Core/Scripting/Network_requests. It focuses on the "fetch" API as the tool for making requests, which is the standard way to make network requests in Javascript. There are other tools like Axios that may make things easier, but "fetch" should be fine for your use case.

Another concept that will be relevant here is asynchronous programming: https://developer.mozilla.org/en-US/docs/Learn_web_development/Extensions/Async_JS/Introducing. Basically, there will be some delay between when you make the request and when you get a response. So you'll need to write your logic in a way that does the "waiting" part correctly.

One important detail is that most APIs use some form of authentication. So when you're "grabbing the data" from an external site, the site knows who you are and that you are allowed to access that data. Getting authentication right might be a little tricky, but here is an entry point: https://developer.mozilla.org/en-US/docs/Web/HTTP/Guides/Authentication. Basically, you'll need to figure out what authentication strategy your headless CMS is using, and then make sure to safely pass those credentials when making your network requests. If the API(s) you are using are public, you won't need to worry about this.

If your goal is primarily to get data from an external source, this should be a good starting point. You don't necessarily need to get too deep into the backend or even the technical details of things like HTTP or REST. However, if you're interesting in getting a deeper understanding of Web APIs, the other comment talking about building a skeleton API would be a good exercise.

[–] jonathan7luke@lemmy.ml 52 points 5 days ago* (last edited 5 days ago) (1 children)

I 100% agree with the idea that rap is certainly not the only genre to glorify violence, drugs, etc. But the specific song choice is not really a great example in my opinion considering the last verse is

C'mon you gotta listen unto me

lay off that whiskey, and let that cocaine be.

This song always struck me as a cautionary tale. Nothing about the song really seems to glorify the behavior.

[–] jonathan7luke@lemmy.ml 3 points 1 week ago

For this specific HN post, speedrunning is a bit of a misnomer. He used similar tooling to effectively add support for a physical keyboard and additionally a bunch of keyboard shortcuts that are capable of inputting custom text, songs, and fabric patterns.

There's a YouTube video where the author showcases this. It's pretty short and a really interesting watch: https://youtu.be/Yw8Alf_lolA

[–] jonathan7luke@lemmy.ml 8 points 1 week ago

I do have enough time, but I don't have the self control. If I could hold myself to an hour a day, that would be fantastic, but I inevitably get myself too addicted and end up spending closer to 4 hours a day. At that point, all my other chores aren't getting done. As a result, I haven't played video games in several years.

[–] jonathan7luke@lemmy.ml 5 points 1 week ago (2 children)

That's a fair point. I was under the assumption that they were still using the "invasion" thing since that was what they leaned into for the deportations. I can definitely see them going with "rebellion" instead.

Seems like there is some (temporary) good news on the topic at least:

A federal judge issued a temporary restraining order Thursday directing President Donald Trump to return control of the National Guard to California.

The order, which takes effect at noon Friday, said the deployment of the Guard was illegal and both violated the Tenth Amendment and exceeded Trump’s statutory authority.

- https://apnews.com/article/california-immigration-national-guard-newsom-trump-lawsuit-aedf8cdd95ee899c9559d5e54a2e4833

[–] jonathan7luke@lemmy.ml 26 points 1 week ago* (last edited 1 week ago) (2 children)

I don't know if there's video footage of Padilla specifically preceding this moment of the press conference, but I think this clip captures most of what happened. Here's a description from AP News:

Padilla interrupted the news conference after Noem delivered a particularly pointed line, saying federal authorities were not going away but planned to stay and increase operations to “liberate” the city from its "socialist" leadership.

- https://apnews.com/article/alex-padilla-noem-immigration-protest-california-f67d220a0254473c53c16aa96f554239

In terms of why he was removed, the article also says this:

In a statement, DHS said that Padilla “chose disrespectful political theater” and that Secret Service “thought he was an attacker.” The statement claimed erroneously that Padilla did not identify himself — he did, as he was being pushed from the room.

Which is obviously a retroactive justification. From what I can tell they did it because it was "disrespectful" to Noem (which is not illegal) and they knew they could get away with it.

EDIT: Found some slightly longer footage here which just shows him pressing towards the front of the group before getting pushed back.

[–] jonathan7luke@lemmy.ml 6 points 1 week ago (4 children)

I appreciate you being upfront about your source, lol. Here's some info from AP News to help clarify a bit.

Typically the authority to call up the National Guard lies with governors, but there are limited circumstances under which the president can deploy those troops. Trump federalized members of the California National Guard under an authority known as Title 10.

- https://apnews.com/article/california-immigration-national-guard-newsom-trump-lawsuit-aedf8cdd95ee899c9559d5e54a2e4833

The relevant part of Title 10 is explained here: https://www.law.cornell.edu/uscode/text/10/12406

Which basically says that the federal government can deploy the National Guard when

the United States [...] is invaded or is in danger of invasion by a foreign nation

So Trump is (falsely) claiming that the protesters are helping Mexico/Venezuela/Wherever to "invade" California. Which is obviously complete horseshit, but unfortunately that same excuse has been working for his other fascist orders such as the deportations to CECOT.

[–] jonathan7luke@lemmy.ml 28 points 1 week ago (14 children)

Math doesn't change, we just learn more about it.

Isn't that true of almost all the sciences?

[–] jonathan7luke@lemmy.ml 28 points 1 week ago

Yeah, if the "surgery" was having your organs harvested. And you're awake enough to feel the pain and observe the horror of what's happening, but without enough strength to stop it.

[–] jonathan7luke@lemmy.ml 51 points 1 week ago (6 children)

Why can't the world have more of this and less of... everything else that's going on right now? 😕

I don't really have a point, it's just sad that humans have the capacity to do such cool, fun, creative things, and instead we're burning the world down so computers can churn out garbage and blowing each other up because we're different from each other.

[–] jonathan7luke@lemmy.ml 7 points 2 weeks ago

The death of social media is kind of fueling the death of human to human communication.

I understand where you are coming from, but I feel the exact opposite. In my opinion, the rise of social media started the decline of real human connection.

Connection over social media is not a substitute for connection with humans in real life, but a lot of times it feels like it can be. I recently made a very deliberate effort to drastically cut back on my social media usage and instead force myself to go out and build community by participating in local groups and events. I've had so many good experiences and made several friends. That feels so much more valuable to me than the hours a day I used to spend doom scrolling.

view more: next ›