nirsky / figma-plugin-react-template

Quickstart your Figma Plugin with this template and tooling.
MIT License
427 stars 83 forks source link

what's the purpose of code.js and code.ts? #2

Closed jessmchang closed 4 years ago

jessmchang commented 4 years ago

i've been editing the controller.ts file, which has been working fine. i assume controller.ts gets compiled into code.ts and .js in the /dist directory. but what are code.js and code.ts in the /src directory? they don't seem to do anything yet when i delete the files, my plugin breaks.

nirsky commented 4 years ago

Hey @jessmchang,
There aren't code.js or code.ts files in src dir.

What we have is:

If you prefer using different names you can change them at the webpack file, under entry, and at manifest.json as well.

Not sure why you see code files in src but if you'll look at the files in this repo you can see it doesn't exist.
I hope that helps?

jessmchang commented 4 years ago

ohh weird. i think some of my files from the figma react plugin persisted somehow. works great now, thanks!