Skip to content

Instantly share code, notes, and snippets.

View davo's full-sized avatar
🏠

Davo Galavotti davo

🏠
View GitHub Profile
@davo
davo / FrameSpy.tsx
Last active November 27, 2019 12:01
FrameSpy - Refactor
import * as React from 'react'
import { addPropertyControls, ControlType, FrameProps, Frame } from 'framer'
import reactElementToJSXString from 'react-element-to-jsx-string'
import Highlight, { defaultProps } from 'prism-react-renderer'
import { themes } from './themes'
import Clipboard from 'react-clipboard.js'
// @steveruizok
// Define type of property
@davo
davo / versions.json
Created October 25, 2019 17:45
TypeScript Version
[
{
'Version number': 0.8,
'Release date': '1 October 2012 (2012-10-01)',
'Significant changes': ''
},
{
'Version number': 0.9,
'Release date': '18 June 2013 (2013-06-18)',
'Significant changes': ''
@davo
davo / Readme.md
Last active August 12, 2019 15:16
Persisting State on Framer X

State Management on Framer X with React

Here is a collection of implementation strategies to manage state on Framer X. Feel free to contribute your own strategies and ideas.

Examples marked with a checkmark mean that some examples has been provided on this repo.

State Management on Framer X

Only for Framer X

@davo
davo / .block
Created August 6, 2019 15:44 — forked from DarienLiang/.block
Transition Between Three Views
license: mit
@davo
davo / ScratchCard.tsx
Created August 1, 2019 23:46
ScratchCard for Framer X
// WIP Refactored from https://github.com/aleksik/react-scratchcard/
import * as React from 'react'
import { Frame, addPropertyControls, ControlType } from 'framer'
export function ScratchCard({ width, height, children, image: source, finishPercent }) {
const [loaded, setLoaded] = React.useState(false)
const [context, setContext] = React.useState(false)
const [isDrawing, setIsDrawing] = React.useState(false)
const [lastPoint, updateLastPoint] = React.useState(null)
@davo
davo / README.md
Last active July 29, 2019 00:46
Moebio Framework - Network Example
@davo
davo / Reset Touchbar.md
Last active July 18, 2019 04:16
Reset Touch or MacOS Mojave

pkill "Touch Bar agent";

killall "ControlStrip";

@davo
davo / Data.tsx
Created June 14, 2019 10:01
Framer X - Type Stack - Data Example
import * as React from 'react'
import styled from '@emotion/styled'
import { css } from '@emotion/core'
import { addPropertyControls, ControlType } from 'framer'
type DataTypes = {
format: 'data40' | 'data30' | 'data20' | 'data10'
}
interface IDataTextProps {
@davo
davo / Colors.tsx
Created May 21, 2019 21:38
Reusing Framer X Shared Colors on a Function Component
import * as React from 'react'
import { Stack, Frame } from 'framer'
import { colors } from './canvas'
export function Colors() {
const [colorsTokens] = React.useState(() => {
return Object.keys(colors).map(key => colors[key])
})
return (

Recursively Remove .DS_Store

find . -name '.DS_Store' -type f -delete