Skip to content

Instantly share code, notes, and snippets.

View moshiurse's full-sized avatar

Moshiur Rahman moshiurse

View GitHub Profile
moshiurse / utilities.css
Created June 2, 2024 15:08
Some common utility CSS
/* Flex */
display: flex;
justify-content: center;
align-items: center;
moshiurse / index.html
Created November 21, 2023 02:44
Image preloading
<div class="container">
<div class="image">
<div class="loader"><img src="loader.gif" alt="Loading..."></div>
<img src="" /></div>
<div class="image">
<div class="loader"><img src="loader.gif" alt="Loading..."></div><img src="" /></div>
<div class="image">
<div class="loader"><img src="loader.gif" alt="Loading..."></div><img src="" /></div>
moshiurse /
Created September 18, 2023 09:54
Shopify App Dedployment Process (Laravel, react)

create a folder in /var/www

cd /var/www

sudo chmod -R 777 .

mkdir slidecart

Getting projects from git repo

moshiurse /
Last active September 11, 2023 09:10
Digitalocean Droplet setup
moshiurse /
Last active August 28, 2023 12:09
Customized docker image for Shopify development

Installed software


apt install curl

curl --version

Nodejs with Nvm

moshiurse /
Created August 24, 2023 01:18
Migration from CRA to Vite

First, install Vite and all React related libraries (here: Vite's React Plugin) as development dependencies:

npm install vite @vitejs/plugin-react --save-dev

Create a vite.config.ts onn root path

import react from '@vitejs/plugin-react';

export default defineConfig(() =&gt; {
moshiurse / index.html
Created August 23, 2023 02:06
CSS GRID example
<!DOCTYPE html>
<html lang="en">
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Css grid</title>
.container {
moshiurse / app.js
Last active August 8, 2023 05:18
Google Map Autocomplete
function initMap() {
var inputs = document.querySelectorAll('.pac-input');
inputs.forEach(input => {
const autocomplete = new google.maps.places.Autocomplete(input);
autocomplete.addListener('place_changed', function() {
moshiurse /
Created July 25, 2023 09:28
Install tar.gz file in linux
  1. Download the desired .tar.gz or (.tar.bz2) file.
  2. Open Terminal
  3. Extract the .tar.gz or (.tar.bz2) file with the following commands

    tar xvzf package.tar.gz
    tar xvjf package.tar.bz2

  4. Navigate to the extracted folder using cd command

    cd package

  5. Now run the following command to install the tarball

    > make