Amit Merchant

Amit Merchant Verified ($10/year for the domain)

A blog on PHP, JavaScript, and more

  • Articles
  • Projects
  • Uses
  • Art
  • Stats
  • About
  • Search
Laravel PHP JavaScript Git React

Implementing scroll snap using only three lines of CSS

March 25, 2022 — If you’re not under the rock and using the internet for quite some time, you most probably have stumbled upon one of these websites where when you scroll through the website, portions of it snap to the viewport automatically.

Read More CSS

Clear all kinds of caches with a single command in Laravel

March 23, 2022 — There are mainly three kinds of caches in Laravel that you need to clear all the related junk files and optimize the performance of the application.

Read More Laravel

Console Logging the Right Way

March 22, 2022 — Haters gonna hate and call you uncultured but when it comes to debugging, doing console.log() is one of best the best ways of all time. Period. Well! sort of!

Read More JavaScript

Check if an array of objects contains a certain key-value in JavaScript

March 21, 2022 — The other day, I was stumbled upon a scenario where I need to check whether there exists at least one key of a certain value in an array of objects.

Read More JavaScript

Refactoring conditionals to callables in PHP

March 16, 2022 — Recently, I came across a very handy tip by Nuno Maduro where you can refactor some of the conditionals in your code to callables to make your code more elegant and readable.

Read More PHP

Using value of state variables right after updating in React.js

March 10, 2022 — Working on one of the apps which built on top of React.js, I stumbled upon a scenario where I needed to use the value of a state variable immediately after it’s updated.

Read More React

Auto dark mode origin trial of Chrome

March 8, 2022 — With every new release, the Chrome team would release new features, improve the existing ones, and fix bugs. But on top of this, the team also ships some of the experimental features, sometimes called origin trials, that developers can try out and give feedback.

Read More ChromeDevTools

Curried event handlers in React.js

March 7, 2022 — When working with React.js components, you might end up in a situation where you would be using an event handler more than once.

Read More React

The new whereNot method in Laravel 9.x

March 4, 2022 — Sometimes, the things you would think are quite obvious and should exist without a doubt don’t exist at all.

Read More Laravel

Safely convert any value to boolean in PHP

February 28, 2022 — Converting some values to boolean is a common task while building applications. Now, these values can be anything.

Read More PHP
Previous 1 ... 21 22 23 ... 62 Next

Awesome Sponsors

Uploadcare
Become a Sponsor
And get featured on this spot

Download my eBook

PHP 8 in a Nutshell

(Includes PHP 8.1 and 8.2)

Newsletter

Subscribe

Follow me everywhere

My Tiny YouTube Channel ➔ YouTube Icon

Recently Published

  • Textareas with auto-increasing height using CSS NEW

  • The many uses of "..." ellipsis operator in PHP

  • Pail — A Laravel Package for Tailing Logs

  • A macro to produce AP-style headings in Laravel

  • Override Fetch/XHR response in Chrome DevTools

Top Categories

Laravel PHP JavaScript Miscellaneous CSS React VS Code Git Jekyll ➔
Home About Contact Categories Links Guestbook
Previous page Next page
Amit Merchant
About Contact Sponsorship Guestbook
Copyright © 2023 — Amit Merchant