Skip to content

Instantly share code, notes, and snippets.

View thisizkp's full-sized avatar

Prasanth Karri thisizkp

View GitHub Profile
@thisizkp
thisizkp / Container.tsx
Created December 20, 2021 01:45
Container component in React v18
import { Suspense, ErrorBoundary } from 'react'
export function Container({ Loader, Error, children }) {
return (
<Suspense fallback={<Loader/>}>
<ErrorBoundary FallbackComponent={<Error/>}>
{children}
</ErrorBoundary>
</Suspense>
)
@thisizkp
thisizkp / git.md
Created October 8, 2018 01:05
Git commands

Delete all branches except "master" from local

git branch | grep -v "master" | sed 's/^[ *]*//' | sed 's/^/git branch -d /' | bash