Internet Weekly #120 | Stefan Judis Internet Building

Internet Weekly #120 | Stefan Judis Internet Building

[ad_1]

When are we able to get started server-rendering shadow DOM? What makes a really perfect code diff view? And the way do you put into effect available notifications?

This week’s Internet Weekly comprises the entire solutions and a lot more. Experience!

I have were given some information. In December, I left my full-time gig at Checkly and now paintings solo. 😅 It is horrifying, yet issues are going truly smartly thus far.

One main a part of this choice was once that I sought after to focal point extra on Internet Weekly. I am dreaming of this article turning into “an actual factor”. May that paintings?

I do not know but, yet if you happen to experience Internet Weekly and need to lend a hand, it might imply the sector. What are you able to do? I am happy you requested!

Thanks!💙

In case you’ve learn final week’s version, I requested if we will have to introduce a group tune phase. And. Right here. We. Are! 🎉

The queue is already crammed for subsequent month. And I will kick issues off with Jay.

Do you need to proportion your favourite tune with the Internet Weekly group? Hit answer, and I will come with it!

One thing that made me smile this week

A ball showing the letter "Y" next to a symbol that looks like an axe.

I simply love the web.

What occurs when you go surfing and ask why this ball in your home has the letter Y revealed subsequent to an Axe?

Folks cross on a treasure hunt to unravel the thriller. 🤣

Remedy the thriller

<!-- Not a CORS request --> <script src="https://example.com/script.js"></script> <!-- CORS request --> <script type="module" src="https://example.com/script.js"></script>

Oldie yet goldie: if you wish to know the way Move-Foundation Useful resource Sharing (CORS) works, and in any case perceive what triggers those bizarre OPTIONS requests, or be told what the headers secure record is, Jake Archibald has you lined!

Perceive CORS

Difference between using aria-live and live region roles.  The primary difference between using live region roles and using aria-live on its own is that live region roles have semantic meaning. They add explicit semantics to an element ("This is an alert", "This is a status message", etc.), so some screen readers may announce “alert” before announcing the content of the message.

Sara Soueidan opened considered one of her accessibility direction chapters — available notifications. What is aria-atomic? When will have to you utilize position=standing? And are there techniques to keep away from notification dealing with for assistive generation altogether?

Sara has the entire solutions. 😉

Notify the precise manner

I wrote down what I realized if you happen to favor a tl;dr.

The “legacy” compatibility effectively removes any incentive to make packages for Deno (or Cloudflare, or Bun). Why use dnt to create packages that are compatible with both Deno and Node when you can just make a Node package? It’s still going to be compatible with both Deno and Node. Deno themselves have seen to that. You’re going to get cross-runtime compatibility either way.

The JavaScript runtime struggle is in complete swing. In fact, there may be Node and all the npm ecosystem.

However then there may be Deno, or Bun, or Cloudflare employees. They all need a bit of of the JavaScript runtime cake. However they’ve one drawback: they are ranging from scratch.

None of those cool children can rebuild or forget about what Node has — the large ecosystem. They usually all will have to be Node appropriate to leverage it.

Baldur Bjarnason shared affordable ideas at the pageant and why Node is there to stick.

Make a selection the most efficient runtime

5 :has() selector varieties

li:has(~ li:not(a))::after { 	content: "/"; 	margin-inline-start: 10px; }

Now that each one browsers send :has(), it is in any case time to appear into the selector. Mojtaba Seyedi outlined 5 :has() use instances:

  • mother or father selector (you almost certainly know that one 😉)
  • earlier sibling selector
  • amount question selector
  • any place selector
  • all-but-me selector

Great naming, Mojtaba. 👏

Write fancy CSS

You are midway thru!

Wowza! Would you experience getting Internet Weekly instantly on your inbox?

The glorious bizarre internet – sitinshade.com

Tip example from Berlin to Rome. Preferred Seating : Right Side. 1505 km / 935.23 miles :15h 20m 58s Sun Exposure Data Left Side: 32.03% Right Side: 20.77% No Sun: 47.20%.

Are you troubled by way of the solar when touring long-distance at the bus? If this is the case, this website online calculates if you happen to will have to take a seat left or proper to reduce solar publicity. 😅

Optimize go back and forth

What are your favourite web corners? Ship them my manner, and I will come with them in Internet Weekly!

A contemporary Node document device API

// read plain text const text = await fsx.text("/path/to/file.txt");  // read JSON const json = await fsx.json("/path/to/file.json");  // read bytes const bytes = await fsx.arrayBuffer("/path/to/file.png");

Nicholas C. Zakas (author of ESLint) is shopping into solving Node’s document device API. And what shall I say? I might find it irresistible if studying and writing recordsdata can be easier.

Write to disk

An imagined code review diff with hidden items and AI summaries.

How do you’re feeling concerning the diff view if you end up doing code evaluations at paintings? Whether or not you utilize GitHub or some other suppliers, the interface is ok. However it isn’t nice, is it?

Mark Otto explores tiny tweaks that would fortify code diffing and code evaluations. And I feel he is onto one thing right here!

Take a look at higher diffs

A carousel that animates out the elements and changes its background color.

Disclaimer: there may be numerous Chrome-only stuff on this carousel, yet it is unbelievable paintings!

Adam Argyle shared how you’ll construct a nearly zero-JavaScript carousel with scroll-driven CSS animations and scroll() / view(). 👏

Animate on scroll

/* Using them with fallback values */ env(safe-area-inset-top, 20px); env(safe-area-inset-right, 1em); env(safe-area-inset-bottom, 0.5vh); env(safe-area-inset-left, 1.4rem);

From the limitless MDN wisdom archive…

Do you know you’ll use CSS env() to position components in a secure viewport subject? env() give a boost to began with iOS and non-rectangular presentations (e.g. env(safe-area-inset-top)) yet now additionally performs a job when transport PWAs (e.g. env(titlebar-area-width)).

Place within the secure subject

TIL recap – text-align-last

p {   text-align: justify; }  p.left {   text-align-last: left; }  p.right {   text-align-last: right; }

In some designs, you will have to align just a paragraph’s final line; is that this imaginable in CSS? It certain is!

Align the final line

Nowadays’s largest information is that Firefox will send Declarative Shadow DOM (DSD).

Declarative Shadow DOM "Can I use" page showing that Firefox supports it with 123.

Why’s this cool? With DSD, you’ll now server render shadow DOM. If the browser helps it, the HTML parser creates your part roots at parse time. And shortly, this magic will paintings throughout engines. 💪

<host-element>   <template shadowrootmode="open">     <slot></slot>   </template>   <h2>Light content</h2> </host-element>

I will go away the query of whether or not you wish to have shadow DOM for every other day and have a good time that every other internet part characteristic is going cross-browser. 🎉

The Chrome people have you ever lined if you wish to be told extra.

3 precious initiatives to take a look at

"Font combinations" next to visually rendered headline / body font combinations.

I have no knack for anything else associated with fonts. Opting for one font is difficult, let on my own settling on a handsome font aggregate. Fontpair can lend a hand out right here!

Pick out the most efficient fonts

The JavaScript ecosystem is converting. Many of us are increasingly more unsatisfied about React — many dream of a more effective stack.

And whilst nonetheless an enormous underdog, htmx assists in keeping arising time and again. However what’s this 3.9k LOC lengthy JS document? Is it a framework? A library? Or each?

Alexander Petros solutions those questions and comes with a forged definition of library vs framework.

A library is a cog that you simply upload on your gadget, a framework is a pre-built gadget that you simply regulate by way of customizing its cogs.

Liked this e mail? Hated this e mail? I need to listen about it!

In case you assume there’s one thing that must be advanced or one thing that you simply loved, respond to this e mail as a result of I need to know extra!

And with that, deal with your self – mentally, bodily, and emotionally.

I will see you subsequent week! 👋

[ad_2]

0 0 votes
Article Rating
Subscribe
Notify of
guest
0 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
Back To Top
0
Would love your thoughts, please comment.x
()
x