Skip to content

Instantly share code, notes, and snippets.

View jjdp's full-sized avatar
🏠
Working from home

Josh de la Peña jjdp

🏠
Working from home
View GitHub Profile
@jjdp
jjdp / use-dropzone.tsx
Created October 18, 2021 08:34 — forked from timc1/use-dropzone.tsx
A React hook that returns whether a file is being dragged into the document from the operating system and not from within the browser.
import React from 'react'
type DropzoneContextValue = {
isDragging: boolean
}
const DropzoneContext = React.createContext<DropzoneContextValue | undefined>(
undefined
)
@jjdp
jjdp / firebase-sandbox.md
Last active February 20, 2018 11:44 — forked from cohenadair/firebase-sandbox.md
Setting up development and production Firebase environments for iOS

Firebase Environments

At the time of writing this gist (January 4th, 2017), I was unable to find true sandboxing to separate development and production environments for a Firebase project. The closest we can get is to create two separate Firebase projects -- one for development and one for production.

Pros

  • Complete separation and isolation of all Firebase features.
  • Freedom to experiment without risking the corruption of production data.

Cons

  • There is no way to copy production data to your development project (that I am aware of).
  • Any settings changes made to your development project also needs to be manually applied to your production project.