DEV Community


Discussion on: What is the best way to organize methods/functions within a file?

khrome83 profile image
Zane Milakovic

I typically avoid classes in JS.

I do put all functions in separate files unless they are really small and make sense together.

I group these files in folders that make sense for the category of work.

I always add a index file that exports the other methods.