Skip Navigation
WordPress.org denies service to WP Engine • The Register
  • Watching web developers react to this change on mastodon has been... interesting to say the least

  • Code Smells Catalog
  • This doesn't seem overly useful.

    It's a list taken out of a bunch of books with no regard for how something can be the best path in one language and a smell in another language.

    Look at this page for example: https://luzkan.github.io/smells/imperative-loops

    It suggests using functional loop methods (.map(), .reduce(), .filter()) instead of using imperative loops (for, for in, for each) but completely disregards the facts that imperative loops also have access to the break, continue, and return keywords to improve performance.

    For example: If I have an unsorted list of 1000 cars which includes a whole bunch of information per car (e.g. color, year manufactured, etc...), and I want to know if there were any cars were manufactured before the year 1980, I can run an imperative loop through the list and early return true if I find one, and only returning false if I haven't found one by the end of the list.

    If the third car was made in 1977, then I have only iterated through 3 cars to find my answer.

    But if I were to try this with only functional loops, I would have to iterate through all 1000 cars before I had my answer.

    A website with blind rules like this is going to lead to worse code.

  • Fandom Wiki Considered Harmful
  • Poor quality red herring comment. Try harder.

  • Which protocol or open standard do you like or wish was more popular?
  • QOI is just a format that's easy for a programmer to get their head around.

    It's not designed for everyday use and hardware optimization like jpeg-xl is.

    You're most likely to see QOI in homebrewed game engines.

  • Which protocol or open standard do you like or wish was more popular?
  • The syntax is only difficult to read in their example.

    I fixed their example here: https://programming.dev/comment/12087783

  • Which protocol or open standard do you like or wish was more popular?
  • I fixed it for you (markdown tables support padding to make them easy to read):

    markdown table
    x y
    |markdown|table|
    |--------|-----|
    |x       |y    |
    
  • Which protocol or open standard do you like or wish was more popular?
  • Chromium had it behind a flag for a while, but if there were security or serious enough performance concerns then it would make sense to remove it and wait for the jpeg-xl encoder/decoder situation to change.

    It baffles me that someone large enough hasn't gone out of their way to make a decoder for chromium.

    The video streaming services have done a lot of work to switch users to better formats to reduce their own costs.

    If a CDN doesn't add it to chromium within the next 3 years, I'll be seriously questioning their judgement.

  • Which protocol or open standard do you like or wish was more popular?
  • I'm under the impression that there's two reasons we don't have it in chromium yet:

    1. Google initially ignored jpeg-xl but then everyone jumped on it and now they feel they have to create a post-hoc justification for not supporting it earlier which is tricky and now they have a sunk cost situation to keep ignoring it
    2. Google today was burnt by the webp vulnerability which happened because there was only one decoder library and now they're waiting for more jpeg-xl libraries which have optimizations (which rules out reference implementations), good support (which rules out libraries by single authors), have proven battle-hardening (which will only happen over time) and are written safely to avoid another webp style vulnerability.

    Google already wrote the wuffs language which is specifically designed to handle formats in a fast and safe way but it looks like it only has one dedicated maintainer which means it's still stuck on a bus factor of 1.

    Honestly, Google or Microsoft should just make a team to work on a jpg-xl library in wuffs while adobe should make a team to work on a jpg-xl library in rust/zig.

    That way everyone will be happy, we will have two solid implementations, and they'll both be made focussing on their own features/extensions first so we'll all have a choice among libraries for different needs (e.g. browser lib focusing on fast decode, creative suite lib for optimised encode).

  • Australia sees hottest winter temperature on record, a brutal 107 degrees
  • That's 41 degrees for everyone who doesn't measure things in bird per gun.

  • CSS Only 3D Robot
  • You should put this in codepen so people don't need to clone a repo to see it.

    For example, here's a 3d css-only thing I was fiddling with: https://codepen.io/spartanatreyu/pen/yPyNjw?editors=0100

  • Deno's Standard Library for JavaScript Finally Stabilized at v1 | 3min 5sec Video | Aug 8, 2024
  • You keep saying "relevance", and now other things like "gimmick" and "marketing".

    Why are you so focused on "relevance"?

    They're completely unrelated to Deno.


    Node had problems, ts-node had problems, Deno fixes those problems for developers.

    Separately, Bun trades solving some problems for solving other problems.

    Developers are free to choose between runtimes based on what problems they encounter.

    Personally I use node for existing web projects and deno for data processing and to compile scripts into redistributable binaries.

  • What to Know About the Blue Supermoon
  • No one's asking nor wondering why you find looking at things in the sky beautiful.

    They're asking why you're ascribing meaning to an arbitrary number of days. Months aren't subjective, they're arbitrary.

  • What to Know About the Blue Supermoon
  • What to know about blue supermoons:

    1. They literally mean nothing.
    2. The change is imperceptible to everyone.
    3. Expect useless clickbait slop about it until it passes.
  • Deno's Standard Library for JavaScript Finally Stabilized at v1 | 3min 5sec Video | Aug 8, 2024
  • stdlib.io is a data process/vis library, not a standard library.

    jQuery was a DOM/Utility DX library (and also a compatibility layer before all browsers finally focussed on standards), not a standard library.

    Deno people are trying so fucking hard to be relevant. It’s embarrassing. Bringing nothing to the table has been their MO from day 1.

    Let's examine that.

    Deno has always been:

    (parapharing) "Hi, I'm the creator of Node and want to make it better but can't get everyone on board with the changes. So I'm going to create a new JS runtime. Node will need to implement these improvements to keep up or everyone will switch away from node. Either way, developers win."

    We know it's been that way since he was a month into Deno's development in his famous talk: 10 Things I Regret About Node.js

    Deno [...] Bringing nothing to the table [...]

    Have a look through each of those 10 points he brought up, then compare that to node before, and node now. It's pretty clear he gave them the swift kick in the ass to start making those changes. We win. That's clearly a success.

  • Deno's Standard Library for JavaScript Finally Stabilized at v1 | 3min 5sec Video | Aug 8, 2024
  • What standard library?

    JS has only had package/library hell

  • Puppeteer Library Improves Firefox Support
  • Who is this article for?

    Firstly, it's basically just a repost of existing info from the mozilla article but now with ads.

    Secondly, the puppeteer team left years ago to work on playwright which is now the better product, which also supports firefox through the webdriver-bidi standard...

    So now I'm wondering... just who was this article for?

  • Is software political?
  • None of what you mentioned is actually about politics, it's just a list of outrage-bait

  • "GitHub" Is Starting to Feel Like Legacy Software
  • I use git log --graph --all --remotes --oneline whenever I need to shell into another computer, but it's still too barebones for regular use.

  • "GitHub" Is Starting to Feel Like Legacy Software
  • What specifically do you think is legacy in that comparison? The coloring? The horizontal layout? The whitespace?

    Note: I've changed the first link from https://github.com/cxli233/FriendsDontLetFriends/network to https://github.com/zed-industries/zed/network. Still the same view, but just a different repo to highlight the problems

    1. It's in a small non-responsive box
    2. Ridiculous spacing
    • If you want to see the commit messages, you either need to hover over a dot which increases visual scanning durations or you need to go to the commits view which only shows the commits on a single branch
    1. It doesn't show commit messages
    2. It's scrolling horizontally
    3. Branches cannot be collapsed
    4. Branches cannot be hidden/ignored
    5. No way to search for commits
    6. No way to select multiple commits
    • Which also means no way to diff any specific commits together
    • And there's also no way to perform an action over a range of commits
    • And there's also no way to start a merge/merge-request/pull-request/etc... between two commits
    1. No way to sort by date/topologically
    2. Keyboard controls only moves view instead of selecting commits

    I'll stop here at 10 reasons (or more if you count the dot points), otherwise I'll be here all day.


    The network view lays out forks and their branches, not only [local]/[local+1-remote] branches.

    Yes, but the others can do that while still being usable.

    I don’t know what IDE that miro screenshot is from. [...]

    It's gitkraken

    [...] But I see it as wasteful and confusing. The author initials are useless and wasteful, picking away focus. The branch labels are far off from the branch heads. [...]

    The picture doesn't do it justice, it's not a picture, it's an interactive view.

    You can resize things, show/hide columns, filter values in columns to only show commits with certain info (e.g. Ignore all dependabot commits), etc... Here's an example video.

    [...]The coloring seems confusing.

    You can customise all that if you want.

  • [css-only] I made a thing

    Feel free to tweak the two custom properties in the css pane to explore the different mosaic patterns that are generated.

    3
    I made a thing

    Single HTML element + CSS only

    1. Inhale for 4 seconds
    2. Hold for 4 seconds
    3. Exhale for 4 seconds
    4. Hold for 4 seconds

    And repeat

    Inspired by: https://quietkit.com/box-breathing/

    Note: The current Safari version has a bugged linear() implementation that has been fixed in the upcoming version.

    3
    Typescript 5.2 Released
    devblogs.microsoft.com Announcing TypeScript 5.2 - TypeScript

    Today we’re excited to announce the release of TypeScript 5.2! If you’re not familiar with TypeScript, it’s a language that builds on top of JavaScript by making it possible to declare and describe types. Writing types in our code allows us to explain intent and have other tools check our code to ca...

    Announcing TypeScript 5.2 - TypeScript
    0
    Opinions on using CSS' last few years of features
    www.smashingmagazine.com Writing CSS In 2023: Is It Any Different Than A Few Years Ago? — Smashing Magazine

    CSS is evolving faster than ever. With all of the new features that are now available — and forthcoming — since we got Flexbox and Grid years ago, the way we write CSS is evolving, too. In this article, Geoff Graham shares which features have had the most influence on his current approaches to CSS, ...

    Writing CSS In 2023: Is It Any Different Than A Few Years Ago? — Smashing Magazine
    0
    High End CSS: Abusing scroll-based-animation to interpolate values through children in a container
    kizu.dev Position-Driven Styles

    After solving the fit-to-width text, stuck state for sticky elements, and scroll shadows, I wondered: how many other items from various CSS wishlists could I solve with scroll-driven animations? A lot. Styling flex and grid rows and columns, staggered animations, wrap detection, and m...

    0
    Typescript 5.2 beta announcement
    devblogs.microsoft.com Announcing TypeScript 5.2 Beta - TypeScript

    Today we are excited to announce the availability of TypeScript 5.2 Beta. To get started using the beta, you can get it through NuGet, or through npm with the following command: npm install -D typescript@beta Here’s a quick list of what’s new in TypeScript 5.2!

    Announcing TypeScript 5.2 Beta - TypeScript

    Shows a great example of JS' new using keyword (similar to defer in D, Go, Swift, etc...)

    1
    A simple hack to compose two js objects together
    developer.mozilla.org Spread syntax (...) - JavaScript | MDN

    The spread (...) syntax allows an iterable, such as an array or string, to be expanded in places where zero or more arguments (for function calls) or elements (for array literals) are expected. In an object literal, the spread syntax enumerates the properties of an object and adds the key-value pair...

    Spread syntax (...) - JavaScript | MDN

    Answer: create a new object with the properties of the two original objects using the spread operator.

    The order you insert the objects into the new merged object determines which object's properties take priority over the other.

    Linked example:

    ```js const obj1 = { foo: "bar", x: 42 }; const obj2 = { foo: "baz", y: 13 };

    const clonedObj = { ...obj1 }; // { foo: "bar", x: 42 }

    const mergedObj = { ...obj1, ...obj2 }; // { foo: "baz", x: 42, y: 13 } ```

    You can find more discussion here: https://stackoverflow.com/questions/171251/how-can-i-merge-properties-of-two-javascript-objects-dynamically

    0
    The Grand Unified Theory of Documentation (AKA: Your project needs all 4 types or you have bad documentation)
    documentation.divio.com Documentation System

    Find the software documentation system for Divio. Includes comprehensive tutorials, how-to guides, technical reference and explanation. Learn more here.

    The mistake most devs make when trying to document their project is that they only make one (maybe two) types of documentation based on a readme template and/or what their mental model of a newcomer needs.

    Devs need to be actively taught that:

    1. Good documentation isn't one thing, it's four. To have good documentation, you need all four distinct types of documentation.
    2. What the four types of documentation are (this is discussed in the link)

    If you don't have all four types of documentation, you have bad documentation.

    7
    spartanatreyu spartanatreyu @programming.dev
    Posts 14
    Comments 175