Sharing a Variable Across HTML, CSS, and JavaScript
Set a variable in Pug, then create an inline script which sets that variable for using in JavaScript and use setProperty to pass it to CSS.
Set a variable in Pug, then create an inline script which sets that variable for using in JavaScript and use setProperty to pass it to CSS.
CSS can truncate text on a single line or on multiple lines, but it always does so from the end of the text. I’ve seen a (bad) trick reversing the text direction to trim text from the front instead, but never from the middle. Christian Heilmann wrote a package to help with this. I agree […]
You can build your own TypeScript build process, and you might want to if you need true type checking and compatibility with a wider ecosystem of tools. But lots of tools, including now Node itself, just accept TypeScript as if it were JavaScript.
TanStack Start enhances the TanStack Router by adding a server layer that improves performance through server-side rendering (SSR) and isomorphic loaders.
“… props that match a property on the Custom Element instance will be assigned as properties, otherwise they will be assigned as attributes.”
TanStack Query, or react-query, simplifies client-side data fetching with features like caching, automatic re-fetching, and error handling. It integrates smoothly with TanStack Router, allowing efficient prefetching and loading states using hooks like useSuspenseQuery.
TanStack Router is one of the most exciting projects in the web development ecosystem right now, and it doesn’t get nearly enough attention. It’s a fully fledged client-side application framework that supports advanced routing, nested layouts, and hooks for loading data. Best of all, it does all of this with deep type safety. This post […]
jQuery for was great and all, but Alpine.js simplifies tasks like data binding and DOM manipulation, providing using a more declarative and clear structure, making it ideal for smaller projects.
If video game development appeals to you on your journey into design and development, you should check out js13kGames, a “coding competition for web game developers, with a 13KB size limit.” The 2024 winners were recently announced, and I find the lot of them outstanding. 13KB is a heck of a constraint. jQuery is like 30k lol. So […]
Paweł Grzybek has a succinct overview of the new things in JavaScript this year, including credit to the people involved. I find it interesting to consider features in the recent light of the JS0/JSSugar proposal/drama. Looking at these features, which ones would be “real language” features (JS0) and which could be processed away (JSSugar)? I […]
Frontend Masters Donates to open source projects. $363,806 contributed to date.