Tokio: Macros ๐
tokio::join! lets you run multiple futures concurrently, and returns the output of all of them. For JavaScript developers: Promise.all is a good equiv [...]
a collection of dev rss feeds - blogroll
Posts
tokio::join! lets you run multiple futures concurrently, and returns the output of all of them. For JavaScript developers: Promise.all is a good equiv [...]
This is a long section. Here are some anchors to jump to the respective part: [...]
Letโs get started with our first Tokio app. Create a new project using Cargo and add the tokio dependency either to your Cargo.toml file or directly o [...]
This guide is a collection of articles and exercises covering how to write network applications with Tokio. Its base is a workshop I gave over the las [...]
Welcome to my new website! I have wanted to create a new and updated version of this page for a long time. In fact, I feel that the old one kept me fr [...]
One thing that I see more often recently is that folks find out about the never type, and start using it more often, especially trying to model error [...]
Iโm writing books about TypeScript and I do workshops and trainings online and in-house. Every time I meet a new group of developers there are some Ty [...]
In the same codebase as last time, we extract data from a HashMap<String, String> called headers, presumably dealing with something similar to HTTP he [...]
The following piece of code takes a PathBuf and extracts the file name, eventually converting it to an owned String. [...]
Oops, I did it again! Iโm writing another book, and itโs again about TypeScript. Iโm happy to announce The TypeScript Cookbook, to be published in 202 [...]
There is rarely a head-scratcher in TypeScript as prominent as trying to access an object property via iterating through its keys. This is a pattern t [...]
Universal JavaScript. JavaScript that works in every environment. JavaScript that runs on both the client and the server, something thinking about for [...]
I missed a little anniversary. Roughly 10 years ago (on April 8, 2012), I started blogging on oida.dev! Time flies! I think this is my longest-running [...]
Rustโs trait system has a feature that is often talked about, but which I donโt see used that often in application code: Implementing your traits for [...]
Usually, when doing TypeScript talks, I just open up a code editor and hack away some cool types that help in a certain scenario. This time, I was ask [...]
โTypeScript and I are never going to be friendsโ. Oh wow, how often have I heard this phrase? Learning TypeScript, even in 2022, can be frustrating it [...]
Learning and teaching Rust has been a big part of me in the last couple of years. Interest in the Rust programming language has brought me to found th [...]
Thereโs a new section on this website! Since today, youโre able to see full coverage of my workshops and talks in the new slides and coverage section. [...]
With the most recent type system features like conditional types or variadic tuple types, one technique to describe a functionโs interface has faded i [...]
Update April 2022: With the update to React 18, a lot of those problems have been fixed. See this pull request for more details [...]
A couple of days ago I found this beauty on the internet: Give up and use any. Thatโs a fantastic website, absolutely hilarious! It also shows how muc [...]
This is a follow-up to Error handling in Rust from a couple of days ago. The moment we want to use error propagation for different error types, we hav [...]
I had the chance to toy around with Deno recently. And with โtoy aroundโ I mean dissecting it into little pieces and see how the sausage was made. So, [...]
I started doing university lectures on Rust, as well as holding workshops and trainings. One of the parts that evolved from a couple of slides into a [...]
Sometimes when writing TypeScript, some of the things youโd usually do in JavaScript work a little different and cause some weird, and puzzling situat [...]
Itโs Tuesday! The day of your weekly dependabot alerts from GitHub! A nice reminder to check on your projects, and usually just a few clicks worth of [...]
The Array.prototype.includes function allows searching for a value within an array. If this value is present, the function returns true! How handy! Of [...]
If you are creating component libraries and design systems in React, you might already have fowarded Refs to the DOM elements inside your components. [...]
I do a lot of architecture work lately, and one thing that seems to appear more often than I thought it would be are module names that have generic-so [...]
My blog is a chronicle of learning new things. Most of the articles I write are notes on how I solved problems that I found in my everyday work. And e [...]
When you are coming from languages like Java, C++, or C#, you are used to doing your error handling by throwing exceptions. And subsequently, catching [...]
I write a lot about TypeScript and I enjoy the benefits it gives me in my daily work a lot. But I have a confession to make, I donโt really like writi [...]
My book TypeScript in 50 Lessons features interludes. Short texts on TypeScript culture that provide room to breathe between heavy, technical tutorial [...]
This is the third article in a series of articles where I want to highlight ways on how to keep your TypeScript code neat and tidy. This series is hea [...]
This is the second article in a series of articles where I want to highlight ways on how to keep your TypeScript code neat and tidy. By nature, this s [...]
This is the first article in a series of articles where I want to highlight ways on how to keep your TypeScript code neat and tidy. This series is hea [...]
Iโve written a new book! On October 6, the pre-release of TypeScript in 50 Lessons started. Itโs 450 pages, published by the wonderful people at Smash [...]
You might have heard of Preact, the tiny 3KB alternative to React. It has been around for a while, and since its inception, it claims to be API and fe [...]
Sometimes when writing JavaScript, I want to shout โThis is ridiculous!โ. But then I never know what this refers to. [...]
Working with real, native, ECMAScript modules is becoming a thing. Tools like Vite, ES Dev server, and Snowpack get their fast development experience [...]
Update: React types for version 18 changed a lot! If you encounter problems described in this article, make sure you update to the latest version! [...]
This list is a collection of component patterns for React when working with TypeScript. See them as an extension to the TypeScript + React Guide that [...]
Recently I wanted to use a ResizeObserver in my application. ResizeObserver recently landed in all major browsers, but when you use it in TypeScript โ [...]
Update: Please note that this article already has some age and Vite has seen significant updates. Also, the Preact team has created their own preset f [...]
Recently, I had to convert a union type into an intersection type. Working on a helper type UnionToIntersection<T> has taught me a ton of things on co [...]
For the redesign of this blog, I created Twitter title cards that are generated automatically. So whenever people share my stuff on social media, they [...]
The other day, I had some friends frowning over the 800KB size of a node application. This brought to my attention that I never really worried about t [...]
TypeScript 4.0 is supposed to be released in August 2020, and one of the biggest changes in this release will be variadic tuple types. And even though [...]
Note: Be very careful with this technique. Better checkout my new approach. [...]
I originally wanted to launch my new website on June 1st, but there were more important things happening at the moment than relaunching a tech blog. T [...]
I recently stumbled upon a question on Redditโs LearnTypeScript subreddit regarding custom React hooks. A user wanted to create a toggle custom hook, [...]
In JavaScript, you can define object properties on the fly with Object.defineProperty. This is useful if you want your properties to be read-only or s [...]
TypeScriptโs control flow analysis lets you narrow down from a broader type to a more narrow type: [...]
boolean is a fun primitive data type in JavaScript. In TypeScript, it allows for a total of four values Wait, four? [...]
If you come from traditional, strongly typed languages you might be familiar with the concept of void: A type telling you that functions and methods r [...]
symbol is a primitive data type in JavaScript and TypeScript, which, amongst other things, can be used for object properties. Compared to number and s [...]
You might well see that my blog starts to center around TypeScript a lot recently. This might look like a strong deviation from what I usually blog an [...]
React typings for TypeScript come with lots of interfaces for all possible HTML elements out there. But sometimes, your browsers, your frameworks or y [...]
Mapped types are great, as they allow for the flexibility in object structures JavaScript is known for. But they have some crucial implications on the [...]
TypeScript is a structural type system. This means as long as your data structure satisfies a contract, TypeScript will allow it. Even if you have too [...]
If you are doing traditional OOP with TypeScript, the structural features of TypeScript might sometimes get in your way. Look at the following class h [...]
Now that we have everything wired up, itโs time to record, direct and stream! If you missed the previous parts, check out the table of contents to qui [...]
We successfully set up the projector in the first chapter. We are able to record the speakerโs video as described in the second chapter. Now let there [...]
We successfully set up the projector in our last chapter. Now itโs time to record the speaker himself. Iโll show you a couple of options how you can r [...]
When we did Scriptโ18 in January 2018, we borrowed an A/V equipment worth of 35.000 EUR to make sure we get kick-ass videos. A+ camera, an A/V mixer a [...]
CSS in JS! In all possible ways. Or at least, in 5 of them. I collected a list of popular ways on how to style React components: emotion, styled compo [...]
This took me exactly one year. But mostly due to not finding a lot to talk about. Typings for React render props are extremely easy and show through t [...]
Is there any topic in the React space that has spawned more controversy than styling? Do everything inline vs rely on classic styles. Thereโs a broad [...]
Render props is, according to the offical docs, a technique for sharing code between React components using a prop whose value is a function. The ide [...]
React has its own, built-in way of type checking called โprop typesโ. Together with TypeScript this provides a full, end-to-end type-checking experien [...]
Welcome to this little primer on TypeScript and React! A match made in heaven! [...]
Hooks have been announced at React Conf 2018. Check out this page for more details. I think theyโre pretty awesome. Probably game-changing! Hooks heav [...]
Reactโs context API allows you to share data on a global level. To use it, you need two things: [...]
React has a built-in way of type checking called prop types. This works at run time and is a great accompanying feature for TypeScript. Iโve added a s [...]
One way to think about TypeScript is as a thin layer around JavaScript that adds type annotations. Type annotations that make sure you donโt make any [...]
Factory functions are a popular tool in JavaScript to create a diversity of objects with a single call. Thereโs a particular factory function that you [...]
JAMStack seems to be one of the most trending topics right now. So are serverless web apps. Hot and loved! Iโve seen some tweets, articles and even li [...]
This post originally appeared on dev.to [...]
When you work on modern JS apps you most likely use Webpack. Webpack always looked like a very complicated build tool to me, until I realised that itโ [...]
Itโs that time of the year again! For the fourth time in a row, Iโm sharing my most favourite conference talks of the year! And again I found some inc [...]
Web apps are really boring if you donโt interact with them. Events are key, and TypeScriptโs React typings have great support for them. [...]
Reactโs context API has be slumbering inside for a while. With one of the latest releases, they decide to open this API to everybody. Itโs very nice t [...]
TypeScript is a natural fit for React, not only because TypeScript is a full fledged JSX compiler. Which means that you donโt need a huge building set [...]
Hereโs a couple of resources that help you getting more out of TypeScript and React: [...]
Components are at the heart of React. Letโs see what we can do to get better error handling and tooling for them! [...]
JSX elements can be nested, like HTML elements. In React, children elements are accessible via the children props in each component. With TypeScript, [...]
TypeScript comes with a ton of built in generic types that ease your development workflow. Hereโs a list of all built-in generic types, with examples! [...]
Type predicates in TypeScript help you narrowing down your types based on conditionals. Theyโre similar to type guards, but work on functions. They wa [...]
If you follow me you know that Iโm super late to the React game. It was not until functional components showed up that I got really interested in the [...]
Hooks are a new feature in React that I personally find pretty exciting. Shortly after their release in React 16.7., people started developing TypeScr [...]
We just started the Call for Presentations for the upcoming DevOne conference, and I couldnโt be more excited. Last yearโs proposals where excellent a [...]
Iโm writing these lines as I fly back from an excellent Angular Connect. I started public speaking a couple of years ago, and this particular talk wil [...]
When starting with TypeScript it took not much time to stumble upon some of the type systemโs odds. Odds that make a lot of sense if you take a closer [...]
When developing, thereโs three things that I absolutely enjoy: [...]
This post was originally published on Medium in 2015. I decided to carry it over to my blog to keep it safe [...]
This post was originally published on Medium in 2015. I decided to carry it over to my blog to keep it safe [...]
For some of my performance audits I need an exact copy of the webpage as it is served by my clients infrastructure. In some cases, it can be hard to g [...]
The other day I was holding a workshop on performance optimisation for single page applications. For this workshop I needed an example that I could op [...]
The almighty JAMStack brings you fast and secure static websites, and with things like headless content management systems they become even easy to ed [...]
After my most favourite tech books and my most favourite tech talks I want to conclude my yearly review with some of podcast episodes I really enjoyed [...]
So it IS finally a tradition. After my most favourite talks of 2015, and the top talks to watch in 2016 โ the conference videos strike back!, we compl [...]
I started taking reading seriously again in 2017. I had highs where I read about 10 books a month (phew), and also lows where I havenโt touched a page [...]
I had the incredible privilege to work with the fine folks at A List Apart on a text concerning resource bundling in the age of HTTP/2. Using the powe [...]
I met Laura from Travis Foundation a couple of years ago at a conference in Austria, and we had some good time and nice chats together. Itโs not easy [...]
I love podcasting. I started back in 2009 and hosted a literature podcast for roughly two years. Thatโs where I made my first steps in producing non-w [...]
One of the great things about Microsoft Edge is that as a developer, you always know what to expect from an upcoming version. Communication is key! Th [...]
About two years ago, Sebastian and I had our first chats about having a JavaScript conference in our town of Linz. And this January, we made our visio [...]
Iโm really good friends with the people at Rising Stack in Budapest. I had lots of fun when they invited me to JSConf Budapest back in May, and enjoy [...]
Back in the day I was an avid reader of The pastry box. You can imagine how super happy I was when Alex, the projectโs creator asked me to contribute [...]
The Perfbytes crew was live at this yearโs Perform conference, interviewing crew, attendees and speakers. I had the chance to have a few minutes with [...]
Itโs super-annoying that the Macโs file OS is case insensitive. Especially if you have a *NIX based server that canโt read your images and things like [...]
Sebastian and I gathered together a list of links and lots of coverage to our conference we held in January. Lots of great blogs, podcasts, images and [...]
This is a somewhat personal post today. Iโm currently in Las Vegas (which would be a story on its own) to speak and attend our companyโs Perform confe [...]
Now that my book is out, I dug up an old workshop I held almost one and a half years ago in Belgium at Devoxx. Devoxx is a special type of conference, [...]
Letโs make this a tradition! I love to watch conference talks. Be it live or on tape. And just like last year I try to collect the talks that I loved [...]
After years of attending conferences and gathering lots of impressions from around the world, my buddy Sebastian and I decided to do our own thing. We [...]
I rarely talk about attending or speaking at conferences, but sometimes you just have to point out some extraordinary events. [...]
Jekyllโs template language Liquid is pretty powerful. We especially use Liquid objects to access different data across all pages, like [...]
Iโm so incredibly happy to have my first article published on Smashing Magazine. Itโs a 6000 word long story about how we managed to bring roughly 200 [...]
We want to convert all our header images to progressive JPEGs to give a good impression of the content to come, rather than having everything line by [...]
I gave a talk on the beloved โSpeed Indexโ metric at this yearโs Topconf in Tallinn. I managed to put the video on Youtube, for all of you to enjoy: [...]
So, Linz has a software conference. One thatโs supposed to stay. I think itโs about time. Linz has a wonderful IT community, with lots of great compan [...]
Recently I did some โThe History of the webโ talks for various institutions. While preparing the story to tell, I remembered one specific tale from 19 [...]
TL;DR: If you want to extend from CoffeeScript written classes, you can use the ES6 class syntax to do so. [...]
TL;DR: NPM Scripts render global installations of NPM command line tools useless. [...]
This filter creates a table of contents list based on all h2 tags that are on your site. [...]
The Gulp task system does not only work with streams alone, but also with other asynchronous patterns. One of those are well known Promises! Find out [...]
I enjoy being at conferences, however I canโt be on all of them. Which is sad, because judging from all the videos one misses a lot! Turns out, my mos [...]
This one is a shorty, but thatโs what it makes it so nice. Imagine that you have only one dependency in your project, which is some third party librar [...]
One of the major changes in Gulp 4 is the new task execution system. In this article, I want to show you whatโs new and how you can migrate the best. [...]
Another article I wrote for the blog over at my employer. When we switched our login from a purely JavaScript based to a progressively enhanced one, w [...]
Node.js 4.0.0 just got released! The jump from 0.12.x to 4.0 is a huge one, especially since it incorporates lots of changes that happened over at the [...]
Incremental builds are a good way of speeding up your build iterations. Instead of building everything again with each and every iteration, you just p [...]
Another nice addition to vinyl-fs that will end up in Gulp 4 is the possibility of having โpassthroughโ source streams. This basically allows gulp.src [...]
This was the first contribution Iโve ever made at GitHub, belonging to the original learn.jquery.com website. The original article is now offline, but [...]
One really cool feature on the Gulp 4 roadmap is the inclusion of native sourcemaps. A commit roughly two weeks ago at the vinyl-fs package makes this [...]
If you want to have a custom _includes directory, and maybe more than one _includes directory, you can easily achieve this by adding a new tag to your [...]
Okay, lovely people, this is huge for me. Iโm actually in the midst of writing a book. Itโs called โFront-End Tooling with Gulp, Bower and Yeomanโ, an [...]
The admin bar in Wordpress can be annoying sometimes, hiding some of your design and even having certain side effects you donโt want. With this snippe [...]
In 2012 I saw one of Lea Verouโs talks for the first time. And if you every had the opportunity of seeing her, you know that you are in for a treat. H [...]
Some sort of follow-up to my first Medium article โ PostCSS Misconceptions โ this one deals with the terms pre- and post-processing in general. Well [...]
The first time I wrote something for my new Job at Ruxit.com. We spent about three weeks to push the siteโs loading performance to a possible max, wit [...]
I tried out Medium as a publishing platform recently. The result is a short rant on how people few PostCSS. While I love the tool and use it everyday, [...]
Last week I attended this yearโs beyond tellerrand in Dรผsseldorf. It was now my third or fourth time (memories are actually really fuzzy โฆ but then ag [...]
One month has passed, many questions on StackOverflow have been answered, so hereโs yet another round of common Gulp issues with a simple and repeatab [...]
I had the sincere pleasure of doing an interview with the guys at bugtrackers.io. We talked a lot about my journey as a web developer for the last 15 [...]
In the last two weeks I spent a good deal of time on StackOverflow, trying to solve every open Gulp question there is. The reasons for that are manifo [...]
With the ever-changing eco system of Node.js tools, a short version disclaimer. This article has been created using [...]
Quite a while ago I wrote a little article on connect middleware and how to run PHP with it. While the article was originally intended to introduce th [...]
Assume you have pushed a commit and regret it now. Or you did want to have that commit in another branch, for development reasons. Itโs rather easy to [...]
Back in 2011 when we started using preprocessors at our company the decision fell very quick to LESS. The reasons for that where mannifold: [...]
You can do the following to revert a single filename to its previous status. [...]
I happen to hold my third iteration of the โFrontend Tooling with Grunt and Yeomanโ workshop at this years JavaScript Days in March. Itโs in Munich, [...]
Those lines send compatibility view instructions with the HTTP Header: [...]
This one restricts authors to only view their own posts in Wordpressโ post overview: [...]
This short snippet restricts authors to only view the files from the media library which they have uploaded: [...]
I did a small contribution to Christophโs blog on โ10 thing that will make you a better developerโ. Be sure to check out the entire article. This one [...]
A few weeks ago I did a short talk on Yeoman at the Linzer edition of Codeweek and how it helps us in our daily workflow. For the first time I tried t [...]
Several ways to fix the problem of running node tools and npm without sudo (which probably always results in an error). [...]
This one gets overlooked the most, I guess. If you have any legal disclaimer, a so called fine print or small print (The ambitious โKleingedruckteโ in [...]
One special version of Excel for instance still adds those nasty buggers. [...]
Useful for wrapper APIs or communicating with external interfaces: [...]
No tutorials or tech guides today, this is something rather personal! Yesterday while waiting for the launch of Netflix I got an E-Mail that the origi [...]
HWB is short for โHue, Whiteness, Blacknessโ and is a new colour space format, which is now proposed in the current CSS Colours Module Level 4 working [...]
Remember those days where developers made the most amazing forms in Flash because they both had to do everything from scratch due to lack of being clo [...]
Recently I had to deploy some static sites for some client, whose server didnโt allow to automatically redirect to index.html when accessing a directo [...]
Update 2016/02: This is old. This might not be up to date anymore! [...]
Last Saturday the very first developer conference of Linz was held at the Ars Electronica Center. A place I havenโt visited for 10 years. It was calle [...]
More than half a year ago I had some little rant on why we should drop using vendor prefixes as a whole. Main points were: [...]
Having a set of reusable and ready software components is a great thing. And for a multitude of reasons, like ensuring DRY development or boosting eff [...]
Even tough I was pretty satisfied with my old blog, and especially its design, I felt the need to go into another round of updating not only the look, [...]
Note: This article is rather old. If you want to know more about `connect`, proceed, if you just want to have a PHP sever with livereload for your Gru [...]
Last week I attended Topconf in Tallinn, Estonia. It was my very first time in Estonia and also my first time at a conference which wasn't targeted to [...]
Titleโs for all content strategists out there who expect something really meta and with a lot of additional bla bla. Well, this is about HTML Content [...]
I'm a huge fan of Emmet. It allows you not only to create markup in no-time by using a CSS-like syntax in your most favourite code editor (e.g. ul>li* [...]
You know parallel scrolling websites? The kind where big sunglasses assemble themselves, break through rocks and crash your browser? The kind everyone [...]
Last friday Jรผrgen Liechtenecker and company held the Digital Visions conference in Vienna for the second time. I was invited to speak and got the ama [...]
Update 2014/01/13: The interface of grunt-contrib-connect has slightly changed. Please check my article on how to add middleware. The proxy middleware [...]
With Effeckt.css I discovered assemble.io, a node-based static site generator for ... well ... assembling HTML files from different parts. [...]
<p></p> <p></p> [...]
I realized recently that I don't have to use "-webkit" on the transition property anymore for Chrome. Actually, to use transitions in modern desktop b [...]
I truly hate social media share buttons. Especially those plugins which not only are coded badly but also create heavy traffic and performance issues. [...]
Update 2021: This has been one of my most read articles for some time. And now I'm happy to proclaim: It's outdated. There's a property in CSS! [...]
Not one single line of JavaScript code? At a conference where web developers visibly outnumbered the rest of the audience? Yes, they can: Dรผsseldorf's [...]
@grigs said I should blog, so I'm going to take this thing seriously now. I spent the last few days (finally) creating a new look for my website. With [...]
There's much buzz going on about HTML5 being just the wrong way of developing apps. Facebook switched to "kind of native" a while ago (and still has a [...]
On Thursday we held the "Technologieplauscherl" at Netural for the first time. The "Plauscherl" (which translates to technology talk, but is unrelated [...]
FOUT is an abbrevation for flash of unstyled text (or type) and is one of those really nasty bits in modern frontend development. Summarized it means [...]
Let's face it: ModX -- even with the Articles Plugin -- isn't suitable for fast blogging. At least not in the way I need it. So I switched back to Wor [...]
Slightly updated on 2014/05/27 [...]
Unbelievable, but true: Imagine you bought a new Windows Phone 7 (e.g. Nokia Lumia or Samsung Omnia) with "Mango" on it and try to get your mobile web [...]
On mobile devices it's pretty easy (and in some cases also pretty cool) to change the look of your website respectively to the orientation of your dev [...]
HTML5 Audio on desktop browsers is a mess. But you haven't experienced true pain and suffering until you try to get HTML5 audio done on mobile devices [...]