Web Tools #549 - CSS/HTML Tools, JS Lib Plugins, Uncats

Web Tools Weekly
WEB VERSION
Tools for Web Developers

Issue #549 • January 25, 2024

Advertisement

Embark On A Web3 Adventure With BitDegree
BitDegree is a leading educational platform at the intersection of technology and learning. With a mission to make education more accessible and engaging, BitDegree offers a diverse range of courses and tutorials, specializing in Web3 and cryptocurrency education.

BitDegree

Explore our platform to unlock a world of knowledge, upskill in cutting-edge technologies, and stay ahead in the ever-evolving digital landscape.

Global Web3 Exam is Live! →

There are a few small but useful utility methods for manipulating strings with JavaScript that you might already be familiar with but I'll review them here. These have support across all modern browsers, so they're quite safe to use.

First of all, there are the String.trimStart() and String.trimEnd() methods. As the names imply, these allow you to trim unnecessary whitespace from the start or end of a string. You can also use String.trim() to remove whitespace from both start and end.

const str1 = "  Example one.",
      str2 = "  Example two.  \n";

console.log(str1.trimStart()); // "Example one."
console.log(str2.trimEnd()); // "  Example two."

Some things to note about these three methods:

  • They all return a new string with the changes applied; the original string is not affected.
  • As demonstrated with the second string example above, the methods will remove space characters as well as line terminators like \n or \r.
  • If the string has no whitespace at the targeted location (start or end) the method will still return a new string, duplicating the original.
  • Previously, browsers implemented support for String.trimLeft() and String.trimRight(). These older methods are deprecated but serve as aliases for the new methods.
  • The methods take no arguments.

Contrariwise, you can also use the String.padStart() and the (you guessed it) String.padEnd() methods to add characters to a given string. Here are two examples:

const str3 = "Example three.";

console.log(str3.padStart(20, "$"));
// "$$$$$$Example three."

console.log(str3.padEnd(22, "%D"));
// "Example three.%D%D%D%D"

These methods work as follows:

  • The first argument is the number of characters you want the string to equal after it has been "padded". If the value is less than the original length of the string, the method will simply return the original string.
  • The second argument is the string to use to "pad" the original string. If it's too long, it will be truncated to match the length specified in the first argument.
  • If you omit the second argument, the string will be padded with space characters by default.
  • Both methods return a new string with the original string intact.
You can try out all the above examples in this CodePen demo.
As mentioned, these are well-supported features and can be easily used to do some simple string-related manipulation. Thus, there's no need to write your own custom functions or to use a fragile dependency and risk breaking things in the future.

Now on to this week's tools!

 

CSS & HTML Tools

@artsy/fresnel — An SSR-compatible approach to CSS media query-based responsive layouts for React.

sparkly-text — A small zero-dependency web component to add animated SVG-based sparkles to text on the page.

TWC — A lightweight solution to help you create reusable React + Tailwind components using a single line instead of the usual multi-line format for React components.

BitDegree Web3 Exam is Here! — BitDegree's Web3 Exam is a global celebration of knowledge, where users test their Web3 skills, win epic prizes, and join a vibrant community. With phases spanning months, it's a unique journey into the heart of decentralized technologies.     SPONSORED 

SVGFM — An online interactive tool to help you learn and create SVG filters, which use the <filter> element along with nested filter primitives.

Chromagen — An npm package that you can use to generate random HSL-based color schemes.

CSS Hooks — A styling solution that adds advanced features to CSS's inline styles with a minimal runtime and no build step.

CSS Hooks

ClassyFont — Upload a font and this tool will generate the necessary CSS to embed it, with options to customize the class name format, folder location, and font stack.

HTMX Playground — A simple code sandbox to write code in a backend-like environment, running entirely inside the browser, for playing around with HTMX syntax, with no setup needed.

Clamp Calculator — An online tool to generate any number of custom fluid tokens that use the CSS clamp() function, for use in typography, spacing, or any other property that accepts a length unit.
 

JS Library Plugins & Tools

svelte-spa-router — A router for Svelte 3 and 4 applications, specifically optimized for Single Page Applications (SPA).

Remix + i18n — A straightforward Remix internationalization example, built on top of react-i18next and remix-i18next.

Svelte Flow — A customizable Svelte component, from the creators of React Flow, for building node-based editors and interactive diagrams.

Svelte Flow

Get Smarter About AI and Tech in 5 min — Receive a daily summary of the most important AI and Tech news, carefully selected from 60+ media outlets. Join 30,000+ professionals from OpenAI, Meta, Google, Microsoft, Hugging Face, JP Morgan, and more.    SPONSORED 

nestjs-fingerprint — A server-side fingerprinting library for NestJS, the Node.js framework, that lets you generate a fingerprint for each browser or device.

drei-vanilla — A growing collection of useful helpers and fully functional, ready-made abstractions for Three.js, the popular WebGL library.

Mismerge — A modern two-way and one-way merge editor for the web, built with Svelte. You can merge using the online demo or use it as a component for your project.

preact-reconciler — An implementation of react-reconciler, which allows for custom renderers to be implemented and shared between Preact and React such as @react-three/fiber.

protomaps-leaflet — A complete web map renderer that includes quality label layout, pattern fills, and icons, powered by Leaflet, the interactive maps library.

Remix + Hono — An adapter that allows you to use Hono (a small and ultrafast web framework for the Edge) with Remix, so you can use the best of each one.
 
Advertisement

The Morning Paper for Hacker News Readers
Want a byte-sized version of Hacker News that takes just a few minutes to read? 

Try TLDR's free daily newsletter.

TLDR covers the most interesting tech, startup, and programming stories in under 5 minutes.

TLDR

No sports. No politics. No weather.

TLDR is read by 1,250,000 software engineers, founders, and tech workers.

Subscribe for Free →


 

The Uncat­egorizables

JSweet — A Java to JavaScript transpiler that creates TypeScript and JavaScript for being run in browsers, mobile Web views, or in Node.js.

Prisma Editor —  A powerful tool designed to visualize and edit your Prisma Schema, with real-time visualization, a user-friendly UI, SQL generation, and more.

AuthKit — An all-in-one authentication solution powered by WorkOS and Radix, the open-source, customizable design system.

Get Smarter About AI and Tech in 5 min — Receive a daily summary of the most important AI and Tech news, carefully selected from 60+ media outlets. Join 30,000+ professionals from OpenAI, Meta, Google, Microsoft, Hugging Face, JP Morgan, and more.    SPONSORED 

Suggestions Files — A simple, human-readable format for suggesting changes to plain text files.

codapi — A platform for embedding interactive code snippets directly into your product documentation, online course or blog post, with support for 14+ languages and 10+ databases.

codapi

Casdoor — A UI-first Identity Access Management (IAM) / Single-Sign-On (SSO) platform supporting OAuth 2.0, OIDC, SAML, and CAS.

Ful.io Technology Profiler — A Chrome extension that lets you see the technologies that a website is built on, with info on tech stack, frameworks, widgets, CDNs, CMSs, and more.

Documenso — An open-source DocuSign alternative, offering a self-hosted solution to digital document signing.

Heynote — A dedicated scratchpad for developers that uses a large, persistent text buffer divided into blocks, and each block can have its own Language set (e.g. JavaScript, JSON, Markdown, etc.) with syntax highlighting and an auto-formatted JSON response.

Commercial Apps and Classifieds

These are commercial apps, affiliate links, PPC ads, and paid classifieds. Buy a Classified here.
Loopliz – Software for adding feature voting and a changelog to your products.
Bytes – A JavaScript newsletter that's informative & entertaining, for all levels of JS devs.    AD 
SuperDev Pro – Fourteen-in-one tool to inspect, edit, refine, and export any website visually.
Resend – An email platform for developers, to deliver transactional and marketing emails at scale.
Passionate Income – Gain financial literacy in a bite-sized 3-minute read that has actionable advice.    AD 
CoderPad – Platform to run coding assessments and collaborative technical interviews with devs.
Ocule – An advanced, cost effective bot blocker with low false positive rates.

An X Post for Thought

Is this too harsh a response to a cold email? Possibly. But I think it's better than the email being ignored and the person not learning why they never got a response.
 
An X Post for Thought
 

Send Me Your Tools!

Made something? Reply to this email or send links via Direct Message on X @LouisLazaris (details here). No tutorials or articles, please. If you have any suggestions for improvement or corrections, feel free to reply to this email.
 

Before I Go...

If you like Wordle and Hex codes, you'll love Hexodle, a daily game that lets you guess a color in Hex format. You get up/down hints for each character, so it's not as difficult as it sounds.

Thanks to everyone for subscribing and reading!

Keep tooling,
Louis
@LouisLazaris
PayPal.me/WebToolsWeekly

Older messages

Web Tools #548 - URL.canParse(), Web Frameworks, Git/CLI Tools, Vue Tools

Thursday, January 18, 2024

WEB VERSION Issue #548 • January 18, 2024 Advertisement Build with the Power of Code — Without Writing Any Take control of HTML, CSS, and JavaScript in a visual canvas. Webflow Webflow generates clean,

Web Tools #547 - Rising Stars, JS Utilities, ChatGPT, Testing & Debugging

Friday, January 12, 2024

WEB VERSION Issue #547 • January 11, 2024 Advertisement The Future of Intelligent Composable Content As the leading intelligent composable content platform, Contentful enables developers and marketers

Web Tools #546 - MediaCapture, CSS/HTML Tools, SVG, Uncats

Thursday, January 4, 2024

WEB VERSION Issue #546 • January 4, 2024 Advertisement Build with the Power of Code — Without Writing Any Take control of HTML, CSS, and JavaScript in a visual canvas. Webflow Webflow generates clean,

Web Tools #545 - Top 30 Tools of 2023

Thursday, December 28, 2023

Web Tools Weekly WEB VERSION Issue #545 • December 28, 2023 Advertisement The Morning Paper for Hacker News Readers Want a byte-sized version of Hacker News that takes just a few minutes to read? Try

Web Tools #544 - The Top Tools of 2023 (Part 1)

Thursday, December 21, 2023

Web Tools Weekly WEB VERSION Issue #544 • December 21, 2023 Advertisement Have You Heard? ClickUp AI Has Officially Launched 😎 Now you can get your work done faster with the only AI-powered assistant

You Might Also Like

Launch pad decongestion

Monday, May 6, 2024

We've got some very cool news from Hubble Networks, which became the first company to connect a Bluetooth chip to a satellite. View this email online in your browser By Aria Alamalhodaei Monday,

Daily Coding Problem: Problem #1433 [Medium]

Monday, May 6, 2024

Daily Coding Problem Good morning! Here's your coding interview problem for today. This problem was asked by Nest. Create a basic sentence checker that takes in a stream of characters and

Want to become an AI consultant?

Monday, May 6, 2024

My take on this new industry ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌

Visualized | Interest Rate Forecasts for Advanced Economies 📈📉

Monday, May 6, 2024

In this graphic, we show the IMF's interest rate forecast for the US, Europe, the UK, and Japan for the next five years ahead. View Online | Subscribe Presented by Voronoi: The App Where Data Tells

⚙️ Apple AI updates

Monday, May 6, 2024

Plus: X AI stories & YouTube "skip to the good part" ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌

Unlock Time Series Data, FTC Chair Joins StrictlyVC & More

Monday, May 6, 2024

TechCrunch Events Roundup | May 6 TechCrunch Events TechCrunch events roundup Unlock the power of time series data with industry experts from AWS and InfluxDB on May 16. Join us next week for this free

Deepdive – product strategy, AI, leadership, emotional intelligence

Monday, May 6, 2024

Earlier this month, we presented our Virtual edition of INDUSTRY: The Product Conference, featuring some of our favorite product leaders worldwide. There were seven great keynote presentations, live

Noonification: The Human Roots of Rising Fascism

Monday, May 6, 2024

Top Tech Content sent at Noon! Get Algolia: AI Search that understands How are you, @newsletterest1? 🪐 What's happening in tech today, May 6, 2024? The HackerNoon Newsletter brings the HackerNoon

Code Story - Apr 24

Monday, May 6, 2024

Welcome to the April addition of the podcast newsletter. Please enjoy, and check out any of the episodes you might have missed below. ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏

Dell turns 40: How a teen founded a tech giant

Monday, May 6, 2024

Samsung's new entry-level OLED TV; Google Threat Intelligence -- ZDNET ZDNET Tech Today - US May 6, 2024 placeholder Dell turns 40: How a teenager transformed $1000 worth of PC parts into a tech