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

What is Framer? Join the Community
Return to index
Joshua Tucker
Posted Mar 12 - Read on Facebook

For you module peeps: attempting to add a switch statement inside an exports function and it's not working. If I use traditional if, else if, and else, it works fine. Missing something, or bug/issue?

6 Comments

Koen Bok

Any specific error?

Koen Bok

I can't come up with a reason why it wouldn't work.

Joshua Tucker

Strangely enough, no. No error, it just simply won't enter the switch statement.

Joshua Tucker

Let me look into this again and see if I was just jacking it up. But I tried a few different ways and tried applying just a basic switch and didn't seem to have luck before.

Joshua Tucker

Follow-up: I'm an idiot. Variables weren't matching (hence why I was getting a ReferenceError for a nonexistent variable).

Koen Bok

Happens to the best of us :-)

Read the entire post on Facebook