This is a read-only archive of the Framer Community on Facebook.

What is Framer? Join the Community
Return to index
Lukas Guschlbauer
Posted Feb 15 - Read on Facebook

Okay just throwing it out there, since I've wrote my first custom layer-classes today and then had the idea:

When importing from Sketch, Symbols with overrides automatically get converted into classes with the overrides as properties...

What do you think? Should be possible I guess..?

3 Comments

Steve Ruiz

I've had a similar idea. Take a look at my fork of the createClass-for-Framer. You can use to easily turn layers into classes once you've imported them. (It works on regular layers too.) I like your idea of having this be part of the import process though! https://github.com/steveruizok/createClass-for-Framer

Lukas Guschlbauer

Oh nice! 👍 Will take a more detailed look tomorrow, but looks promising! I'm wondering if the better approach would be to write a Sketch-Plugin where you select a symbol and can say "copy as framer class to clipboard", so you have more control... what do you think?

Steve Ruiz

Hm, probably a little of both, as you'd still need to tell Framer to create a class out of whatever comes in from Sketch. In the short term, you can use this code with the module I posted to convert all layers that have a particular prefix into classes. https://codeshare.io/GbvmgA

Read the entire post on Facebook