A simple framer module containing essential functions useful in most projects. It will be updated with other useful functions. Feel free to add or suggest new one 😀
- Download the
essentials.coffee
file - Create a Framer project and add the file in
/modules
- At the top of the Framer document write
{array of the functions you want to use} = require "essentials"
{rT, stopProp} = require "essentials"
Function that returns your value converted to retina. Useful when you prototype in sketch and import @2x.
width: rt(200) #Will return a width of 400 pixels on screen
Function that stop the propagation of events to parent layers. Useful when you listen for the event on a layer and on its parent but you don't want the parent's event to fire when you click on the child.
stopProp(myLayer) #Won't fire events on parents
Framer-app-base is released under the MIT license.
Twitter: @benjarier