Webdevelopment Tailored for 2024

Rate this content
Bookmark
SlidesProject website

Most developers closely follow the framework wars. So busy with these games, that we forget to check what new features HTML, CSS, and JavaScript offer us. Native modals, dynamic viewport units, and optional chaining are just some of the features you should use already! If you stopped following Web Platform development in 2015, it's time to refresh your knowledge. I will teach you to build applications tailored to 2024 and prepare you for the new Web Platform features that will appear in the coming years.

This talk has been presented at React Summit 2024, check out the latest edition of this React Conference.

FAQ

The Interop Project is a collaborative initiative started in 2021 involving all major browsers. Its goal is to provide web developers and users with web platform features that work consistently across all browsers.

Native features are generally faster than user-implemented solutions, remain available even if frameworks or libraries change or become obsolete, make debugging easier, and can significantly improve the performance and aesthetics of web applications.

Dynamic viewport units, part of Interop 2022, solve issues related to varying viewport sizes on mobile devices. They ensure that elements take up the correct amount of space regardless of whether the viewport is small or large, making designs more responsive.

The 'gap' property, implemented as part of Interop 2021, allows developers to define the spacing between elements in Flexbox and Grid layouts without having to use margins or padding, thus simplifying layout design.

Container queries allow developers to change the style of an element based on the size of its container rather than the entire viewport. This feature, part of Interop 2023, enables more responsive and adaptable designs.

The subgrid feature, introduced in Interop 2023, allows child elements to inherit the grid layout of their parent elements. This is useful for creating complex layouts as it simplifies the management of nested grid structures.

Offscreen canvas allows 3D animations and other graphical computations to be processed on a different thread than the main UI thread. This improves performance by preventing the main UI from hanging, enabling smoother animations.

The CSS scroll-behavior property allows for smooth scrolling between different parts of a webpage with a single declaration. This enhances user experience by providing a more seamless navigation experience.

CSS clipping and masking, improved as part of Interop 2023, allow developers to create complex visual effects such as clipping DOM elements to various shapes and animating these shapes. This can make web designs more dynamic and visually appealing.

In 2024, web developers can look forward to full cross-browser support for native CSS nesting and entry-exit animations. These features will enable more complex and refined style sheets and transitions in web designs.

Andrzej Fricze
Andrzej Fricze
7 min
18 Jun, 2024

Comments

Sign in or register to post your comment.

Video Summary and Transcription

Today's Talk covers native features in browsers, including upcoming ones and the Interop Project. Native features offer speed, compatibility, and improved debugging. Notable examples include dynamic viewport units, flexbox/grid gap, container queries, and motion path. The Interop Project ensures consistent web platform features across different browsers. Upcoming features like native CSS nesting and entry/exit animations are on the horizon.
Available in Español: Desarrollo web adaptado para 2024

1. Native Features in Browsers

Short description:

Today I'll talk about native features in browsers and upcoming ones. Native features are faster, available even when frameworks change, and make debugging easier. Some are magical and can enhance application performance and aesthetics. Interop Project ensures consistent web platform features across all browsers. Not claiming ownership, just demonstrating examples. Notable native features include dynamic viewport units, flexbox/grid gap, container queries, subgrid, offscreen canvas, motion path, CSS scroll behavior, CSS clipping/masking, and HES selector.

Hi, guys. Today I'll talk about native features that we already have in browsers and some new native features that will be coming to our browsers in upcoming months and years. Why would I talk about especially native features? First of all, they are generally faster than user-learned implementations, but they will be available even when your favorite framework or library changes or dies because it might happen. Knowing native features make debugging easier because that's in the end the language that browsers pick, that's the real implementation in the browser, so it's good to understand how it works. And some of native features are actually magic and you want to use them in an application to make your application more performant or more beautiful.

Before I show you some of those features, I need to mention Interop Project. Interop Project is a very important project that under this name started in 2021 and is still ongoing and it's a cooperation of all the major browsers to provide us web developers and provide our clients with web platform features that work consistently in the same manner across all browsers. And just a little disclaimer, some examples in this presentation are not mine and I do not claim ownership, I just wanted to show you the best examples of those native features and how they work.

First of all, first native feature that was a part of Interop 2022, so in 2022 all browsers decided they need to implement this feature consistently across all of them, so dynamic viewport units, they solved an issue that you could have had before with small viewport and large viewport existing on mobiles. So if you were using viewport height unit in your CSS it was a problem because on mobile, on desktop this problem does not exist but on mobile there is small viewport and large viewport and one viewport unit was just not enough to cater for that. And currently, we have this small viewport height and large viewport height and we also have a dynamic viewport height so that's actually the best unit to use in most cases and it works as you would expect. So if you use 100 dynamic viewport heights your window, your DOM element will always take the 100% of available viewport height, even on mobile.

Another interesting new feature that was implemented across browsers as a part of Interop 2021 is a gap for flexbox and grid. So finally no more margin issues, no more padding issues, you just say what's the gap between your elements in flex, in grid and you get the gap you'd expect. We have container queries as part of Interop 2023 and this is just a lovely feature when you can change the style of your element based on the size of the container, not only whole and I think this lovely demo shows how useful container queries might be. As part of the same Interop 2023, we've got subgrid. So with just one declaration of grid as you see on the, I'm sorry, oh, this is the one I wanted to show you. So with one declaration of our main grid, we can go in children of this grid and use subgrid as you see here. And then all of those children and even children of those children are laid out on the grid of the parent, which is super useful for creating complicated layouts on your site. We've got offscreen canvas so you can do performant 3D as you can see here, 3D animations on different thread than your main thread. So this can be as complicated as you like and it will not hang your main UI. We have motion path as part of Interop 2023 that allows us to easily create such lovely animations where your element animates exactly on the given path. As you can see in here, in this lovely planet animation. We have CSS scroll behavior for smooth scrolling. So we've just one declaration, scroll behavior smooth, and using link anchors, I can smoothly scroll between different parts of my page. Then as Interop 2023, we've been given good implementations of CSS clipping and masking. So we can do crazy stuff like that with text, GIF can be a background for text, or you can clip your DOM elements to a many, many different and wild shape. And you can also animate those clips path. We've been given HES selector. So parent selector that's super useful, for example, for creating complicated and showing complicated form states.

2. Upcoming Native Features and Interop Project

Short description:

Native CSS nesting, native models, and entry exit animations are upcoming features. They enhance style sheet creation and UI design. Follow the Interop project for the latest cross-browser implemented features. Reliable and ready to use.

Also as part of Interop 2023, in 2024, we should be given a full cross-browser support for native CSS nesting, which is really, really useful for creating, you know, bit more complicated style sheets.

As part of Interop 2022, we've been given native models, which work really, really nice. All of this is just native dialogue element without much JS or CSS. It just works natively. And I think it's really, really great. It's very useful UI part.

And also in 2024, we should be given full support for entry exit animations. So we'll be able to do such crazy stuff as adding display known, for example, at the end of our keyframes animation of our transitions. And that's it. I wanted to show you that we have some new great features already implemented and coming to a platform. I wanted to mention that you should follow Interop project to get your latest knowledge about great new features that are being implemented cross-browsers safely. That you can rely on them and, you know, go on, use them. Thank you so much.

Check out more articles and videos

We constantly think of articles and videos that might spark Git people interest / skill us up or help building a stellar career

A Guide to React Rendering Behavior
React Advanced Conference 2022React Advanced Conference 2022
25 min
A Guide to React Rendering Behavior
Top Content
This transcription provides a brief guide to React rendering behavior. It explains the process of rendering, comparing new and old elements, and the importance of pure rendering without side effects. It also covers topics such as batching and double rendering, optimizing rendering and using context and Redux in React. Overall, it offers valuable insights for developers looking to understand and optimize React rendering.
Don't Solve Problems, Eliminate Them
React Advanced Conference 2021React Advanced Conference 2021
39 min
Don't Solve Problems, Eliminate Them
Top Content
Kent C. Dodds discusses the concept of problem elimination rather than just problem-solving. He introduces the idea of a problem tree and the importance of avoiding creating solutions prematurely. Kent uses examples like Tesla's electric engine and Remix framework to illustrate the benefits of problem elimination. He emphasizes the value of trade-offs and taking the easier path, as well as the need to constantly re-evaluate and change approaches to eliminate problems.
Scaling Up with Remix and Micro Frontends
Remix Conf Europe 2022Remix Conf Europe 2022
23 min
Scaling Up with Remix and Micro Frontends
Top Content
This talk discusses the usage of Microfrontends in Remix and introduces the Tiny Frontend library. Kazoo, a used car buying platform, follows a domain-driven design approach and encountered issues with granular slicing. Tiny Frontend aims to solve the slicing problem and promotes type safety and compatibility of shared dependencies. The speaker demonstrates how Tiny Frontend works with server-side rendering and how Remix can consume and update components without redeploying the app. The talk also explores the usage of micro frontends and the future support for Webpack Module Federation in Remix.
Impact: Growing as an Engineer
React Summit 2022React Summit 2022
27 min
Impact: Growing as an Engineer
Top Content
This Talk explores the concepts of impact and growth in software engineering. It emphasizes the importance of finding ways to make the impossible possible and the role of mastery in expanding one's sphere of impact. The Talk also highlights the significance of understanding business problems and fostering a culture of collaboration and innovation. Effective communication, accountability, and decision-making are essential skills for engineers, and setting goals and finding sponsors can help drive career growth. Feedback, goal setting, and stepping outside of comfort zones are crucial for personal development and growth. Taking responsibility for one's own growth and finding opportunities for impact are key themes discussed in the Talk.
Speeding Up Your React App With Less JavaScript
React Summit 2023React Summit 2023
32 min
Speeding Up Your React App With Less JavaScript
Top Content
Watch video: Speeding Up Your React App With Less JavaScript
Mishko, the creator of Angular and AngularJS, discusses the challenges of website performance and JavaScript hydration. He explains the differences between client-side and server-side rendering and introduces Quik as a solution for efficient component hydration. Mishko demonstrates examples of state management and intercommunication using Quik. He highlights the performance benefits of using Quik with React and emphasizes the importance of reducing JavaScript size for better performance. Finally, he mentions the use of QUIC in both MPA and SPA applications for improved startup performance.
React Concurrency, Explained
React Summit 2023React Summit 2023
23 min
React Concurrency, Explained
Top Content
Watch video: React Concurrency, Explained
React 18's concurrent rendering, specifically the useTransition hook, optimizes app performance by allowing non-urgent updates to be processed without freezing the UI. However, there are drawbacks such as longer processing time for non-urgent updates and increased CPU usage. The useTransition hook works similarly to throttling or bouncing, making it useful for addressing performance issues caused by multiple small components. Libraries like React Query may require the use of alternative APIs to handle urgent and non-urgent updates effectively.

Workshops on related topic

React Performance Debugging Masterclass
React Summit 2023React Summit 2023
170 min
React Performance Debugging Masterclass
Top Content
Featured WorkshopFree
Ivan Akulov
Ivan Akulov
Ivan’s first attempts at performance debugging were chaotic. He would see a slow interaction, try a random optimization, see that it didn't help, and keep trying other optimizations until he found the right one (or gave up).
Back then, Ivan didn’t know how to use performance devtools well. He would do a recording in Chrome DevTools or React Profiler, poke around it, try clicking random things, and then close it in frustration a few minutes later. Now, Ivan knows exactly where and what to look for. And in this workshop, Ivan will teach you that too.
Here’s how this is going to work. We’ll take a slow app → debug it (using tools like Chrome DevTools, React Profiler, and why-did-you-render) → pinpoint the bottleneck → and then repeat, several times more. We won’t talk about the solutions (in 90% of the cases, it’s just the ol’ regular useMemo() or memo()). But we’ll talk about everything that comes before – and learn how to analyze any React performance problem, step by step.
(Note: This workshop is best suited for engineers who are already familiar with how useMemo() and memo() work – but want to get better at using the performance tools around React. Also, we’ll be covering interaction performance, not load speed, so you won’t hear a word about Lighthouse 🤐)
React, TypeScript, and TDD
React Advanced Conference 2021React Advanced Conference 2021
174 min
React, TypeScript, and TDD
Top Content
Featured WorkshopFree
Paul Everitt
Paul Everitt
ReactJS is wildly popular and thus wildly supported. TypeScript is increasingly popular, and thus increasingly supported.

The two together? Not as much. Given that they both change quickly, it's hard to find accurate learning materials.

React+TypeScript, with JetBrains IDEs? That three-part combination is the topic of this series. We'll show a little about a lot. Meaning, the key steps to getting productive, in the IDE, for React projects using TypeScript. Along the way we'll show test-driven development and emphasize tips-and-tricks in the IDE.
Web3 Workshop - Building Your First Dapp
React Advanced Conference 2021React Advanced Conference 2021
145 min
Web3 Workshop - Building Your First Dapp
Top Content
Featured WorkshopFree
Nader Dabit
Nader Dabit
In this workshop, you'll learn how to build your first full stack dapp on the Ethereum blockchain, reading and writing data to the network, and connecting a front end application to the contract you've deployed. By the end of the workshop, you'll understand how to set up a full stack development environment, run a local node, and interact with any smart contract using React, HardHat, and Ethers.js.
Remix Fundamentals
React Summit 2022React Summit 2022
136 min
Remix Fundamentals
Top Content
Featured WorkshopFree
Kent C. Dodds
Kent C. Dodds
Building modern web applications is riddled with complexity And that's only if you bother to deal with the problems
Tired of wiring up onSubmit to backend APIs and making sure your client-side cache stays up-to-date? Wouldn't it be cool to be able to use the global nature of CSS to your benefit, rather than find tools or conventions to avoid or work around it? And how would you like nested layouts with intelligent and performance optimized data management that just works™?
Remix solves some of these problems, and completely eliminates the rest. You don't even have to think about server cache management or global CSS namespace clashes. It's not that Remix has APIs to avoid these problems, they simply don't exist when you're using Remix. Oh, and you don't need that huge complex graphql client when you're using Remix. They've got you covered. Ready to build faster apps faster?
At the end of this workshop, you'll know how to:- Create Remix Routes- Style Remix applications- Load data in Remix loaders- Mutate data with forms and actions
Vue3: Modern Frontend App Development
Vue.js London Live 2021Vue.js London Live 2021
169 min
Vue3: Modern Frontend App Development
Top Content
Featured WorkshopFree
Mikhail Kuznetcov
Mikhail Kuznetcov
The Vue3 has been released in mid-2020. Besides many improvements and optimizations, the main feature of Vue3 brings is the Composition API – a new way to write and reuse reactive code. Let's learn more about how to use Composition API efficiently.

Besides core Vue3 features we'll explain examples of how to use popular libraries with Vue3.

Table of contents:
- Introduction to Vue3
- Composition API
- Core libraries
- Vue3 ecosystem

Prerequisites:
IDE of choice (Inellij or VSC) installed
Nodejs + NPM
Developing Dynamic Blogs with SvelteKit & Storyblok: A Hands-on Workshop
JSNation 2023JSNation 2023
174 min
Developing Dynamic Blogs with SvelteKit & Storyblok: A Hands-on Workshop
Top Content
Featured WorkshopFree
Alba Silvente Fuentes
Roberto Butti
2 authors
This SvelteKit workshop explores the integration of 3rd party services, such as Storyblok, in a SvelteKit project. Participants will learn how to create a SvelteKit project, leverage Svelte components, and connect to external APIs. The workshop covers important concepts including SSR, CSR, static site generation, and deploying the application using adapters. By the end of the workshop, attendees will have a solid understanding of building SvelteKit applications with API integrations and be prepared for deployment.