Framer Snippets Library

68 Repeatables For A Faster Workflow

Charlie Deets
Design at Meta
3 min readJul 18, 2016

--

Download here: https://github.com/robotdestroy/Framer-Snippets-Library

In a previous article about how I work with Framer and Sketch in my workflow I mentioned one of my favorite snippets, which slowed down all the animations of a project. It received quite a few highlights, so I felt it would be cool to publish my snippets library in the Facebook Design Resources. Our goal is to help spread great design tools to the larger design community, so we hope you find these useful!

I built this library to complement the included snippets library in Framer. These snippets focus on repeated actions and include as little code as possible. It should be quite helpful to beginners who are learning the basic behaviors of Framer, but it should be also be helpful to more experienced users when used as shortcuts.

Install

  • Open Framer
  • Tap snippets icon
  • Show snippets folder
  • Either clone or download snippets to folder

Actions

A variety of common actions.

  • Click
  • Keydown
  • Touch Start
  • Touch Move
  • Touch End

Animate

The animate snippets are a variety of common animation starters. Including scale, opacity, and position. Choose the one that makes the most sense and customize it to your needs.

  • Opacity
  • Position
  • Scale
  • Dimensions
  • Rotation
  • With Delay

Trigger On End
Included are two ways to trigger an animation on the end of another animation. The formal one should be used when you intend on reusing the animations, the casual one can be used for one off triggering.

Repeating
This snippet allows you to create an infinite loop of two animations. The ‘Halt’ snippet will stop the repeating animation.

Slow Motion
This will allow you view your prototypes in slow motion to more finely tune your animations.

Drag

  • Start
  • Move
  • End
  • Postion

Use these to trigger events from drag actions. Position reports back the current drag position, use it to trigger events when you drag an object into a trigger area.

Layer Properties

Use these to effect your layers.

  • Blur
  • Border
  • Center
  • Circle Shape
  • HTML
  • Image
  • Name
  • Saturation
  • Shadow
  • Style
  • Place Before & Behind
  • Bring To Front & Send To Back

Scroll

Position
Reports back scroll position. You can use this to trigger events that need to occur at certain positions of a scrollLayer.

Direction Lock
Locks scrolling to one direction at a time

Velocity
Reports back velocity of scroll.

Simple Click and Touch

  • Click
  • Touch Start
  • Touch Move
  • Touch End

Very simple click and touch listeners. Use Click when you want immediate feedback. Touch allows more control over the touch event, but has a small delay.

Slow Motion

This will allow you view your prototypes in slow motion to more finely tune your animations.

Spring

  • Fast
  • Loose
  • Slow
  • Variables Setup

Some starter springs. The variable setup snippet allows you to create reusable springs. Place this at the beginning of your file. Use the variable name in place of springs throughout your document.

Other

Delay Utility
Delays anything.

Interval Utility
Fires off code on a repeating interval.

Device Check
Checks to see what device the project is being run on.

Project Setup Example
An organized way to set up your projects.

Follow Me

--

--