How to use web components in React with Typescript

When building a Laravel Inertia React application with TypeScript, I encountered an issue where custom web components were not recognized by TypeScript, even after importing and defining their types. This post documents how I resolved this issue for my Rich Text Editor component, but the solution applies to any custom web component. The Problem TypeScript […]

Read More →

Exmaple with useContext in React JS functional components

In this brief article, we will discuss the effective implementation of useContext. For those unfamiliar, useContext is a technique for sharing state within an application between various components, without requiring the passing of parameters from parent components to each child component. This approach facilitates component modularization and eliminates the need for additional properties that are […]

Read More →

React JS Tags component

I was looking for some light weight Tags component found Tagify to be interesting. But then figured out it got many features which I will not use. So I wanted to create something very minimalist. I found athe following article to follow as I wanted save time while creating this. https://jerrylowm.medium.com/build-a-tags-input-react-component-from-scratch-1524f02acb9a But that article was […]

Read More →

JavaScript functions

Adding some of the JavaScript functions which could use in your projects. Most of them are from my React projects using as functional components in Helper.js file. Unique id function This can be used when needs to generate unique ids for the item. I have created this for generating unique ids for new space and […]

Read More →