Skip to content

Instantly share code, notes, and snippets.

View imbharat420's full-sized avatar
🃏
Bug

Bharat Singh imbharat420

🃏
Bug
View GitHub Profile
@imbharat420
imbharat420 / AbortController Debounce.js
Created September 2, 2024 12:47
AbortController Debounce.js
function debounce(fn,delay){
let timeoutid =0;
let abortController = new AbortController()
return function(...args){
if(timeoutid){
clearTimeout(timeoutid)
abortController.abort();
}
abortController = new AbortController()
@imbharat420
imbharat420 / uploadNext.js
Last active August 29, 2024 18:48
formData in nextjs
import { NextResponse } from 'next/server';
import fs from 'fs';
import path from 'path';
export async function POST(request) {
try {
// Parse the form data
let form = await request.formData();
const blob = form.get('file');
const filename = form.get('name');
@imbharat420
imbharat420 / fibonacci.js
Created August 13, 2024 14:56
Practice Algorithms Patterns
const fib = (num) =>{
if(num==0) return 0
if(num==1) return 1
return fib(num - 1) + fib(num-2)
}
console.log(fib(6))
const fibSeries = (num)=>{
let arr =[0,1]
[
"\n\t\t11i System Administrator Certified Expert certification\n\t\t",
"\n\t\t11i Workflow Certified Expert Certification\n\t\t",
"\n\t\tACFE Alcatel-Lucent OmniAccess Unified Service Gateway (USG) Routers R3 Certification\n\t\t",
"\n\t\tACFE Alcatel-Lucent OmniAccess Wlan R6 Certification\n\t\t",
"\n\t\tACFE Alcatel-Lucent OmniPCX Enterprise R10 Certification\n\t\t",
"\n\t\tACFE Alcatel-Lucent OmniStack LS6200 R1 Certification\n\t\t",
"\n\t\tACFE Alcatel-Lucent OmniStackable LAN Switch R6 Certification\n\t\t",
"\n\t\tACFE Alcatel-Lucent OmniSwitch R6/R7 Certification\n\t\t",
"\n\t\tACFE Alcatel-Lucent OmniTouch 8460 Advanced Communications Server R8 Certification\n\t\t",
// Online C++ compiler to run C++ program online
#include <iostream>
#include <vector>
using namespace std;
void merge(vector<int>& arr, int start, int mid, int end) {
int len1 = mid - start + 1;
int len2 = end - mid;
Domain Cname Provider IsVulnerable IsTakenOver Response
academy.shopify.com nara-39827.herokussl.com. heroku false false There's nothing here
b.ssl.shopify.com shops.myshopify.com. shopify true false Only one step left!
b.ssl.shopify.com shops.myshopify.com. shopify true false Sorry, this shop is currently unavailable.
c.ssl.shopify.com shops.myshopify.com. shopify true false Only one step left!
c.ssl.shopify.com shops.myshopify.com. shopify true false Sorry, this shop is currently unavailable.
crafted.shopify.com craftedgoods.myshopify.com. shopify false false Only one step left!
crafted.shopify.com craftedgoods.myshopify.com. shopify false false Sorry, this shop is currently unavailable.
d.ssl.shopify.com shops.myshopify.com. shopify true false Only one step left!
d.ssl.shopify.com shops.myshopify.com. shopify true false Sorry, this shop is currently unavailable.
@imbharat420
imbharat420 / Record Audio.ts
Last active March 18, 2023 13:52
Record React Native Audio
import React, {useState, useEffect} from 'react';
import {Text, View, StyleSheet, Button, PermissionsAndroid} from 'react-native';
import AudioRecord from 'react-native-audio-record';
import {Buffer} from 'buffer';
import Sound from 'react-native-sound';
import Permissions from 'react-native-permissions';
const Listen = () => {
const [sound, setSound] = useState<any>(null);
const [isRecording, setIsRecording] = useState(false);
@imbharat420
imbharat420 / DateChecker.js
Last active March 11, 2023 13:27
Date Checker implementation for basic use cases
//date format: 1678452212622
const DateChecker = (date) => {
const then = new Date(date);
const [day, month, year] = [then.getDate(), then.getMonth(), then.getFullYear()];
const [hour, minute, second] = [then.getHours(), then.getMinutes(), then.getSeconds()];
return {
getDay: () => day,
getMonth: () => month,
getYear: () => year,
getHour: () => hour,
@imbharat420
imbharat420 / usePictureInPicture.js
Created January 16, 2023 15:42
Picture in Picture React Hook
import { useState, useEffect } from 'react';
function usePictureInPicture(videoRef) {
const [pictureInPictureEnabled, setPictureInPictureEnabled] = useState(false);
useEffect(() => {
if (!videoRef.current) return;
const video = videoRef.current;
function onEnterPictureInPicture() {

I've recently joined Amazon Dublin from India and got opportunities to interview with Meta London, Zalando Berlin & some other companies. I extensively researched about companies hiring internationally which support visa & relocation for Tech roles. So sharing list of companies:

Do consider to STAR, if it helped you.

London