what’s the best practice for naming methods.
I’ve seen where methods are named …but part of me wants to name things so that related things are grouped together.
Though we shouldn’t have ton of methods (or we probably need to refactor), thought I’d ask the question
I know of at least two good naming patterns. One describes what the method does (openIssue for example) and the other describes when it is called (initialize, handleClick, afterRead).
Consolidating methods to make the list shorter probably won’t help much. Keeping each method distinct lets you call a method from many different places. If you have a large number of methods on your page or component, it may be a sign that you should refactor the component and “push down” some of the elements, properties and methods into a subcomponent.