Automattic / wp-cldr

Use CLDR localization data in WordPress
GNU General Public License v2.0
23 stars 6 forks source link

verbs in method names? #60

Closed stuwest closed 8 years ago

stuwest commented 8 years ago

Looking over the first pass of API docs at http://automattic.github.io/wp-cldr/class-WP_CLDR.html, it jumps out that we sometimes use a verb in method names (e.g. get_cldr_locale() and get_cldr_json_file()) but sometimes we don't (e.g territory_name(), languages_by_locale()).

Feels like we ought to use verbs for everything and switch to get_ for each of different functions? A pain, but easier now than after 1.0 releases.

What do you think @jblz?

jblz commented 8 years ago

It looks like the ones where the get_ prefix is so conspicuously missing are those that we originally had prefixed by a _ in emulation of the core translation functions. It definitely makes sense to be consistent here, but we should keep in mind that these are the the functions that devs will be typing out the most, so pith is a virtue. Your call :)

stuwest commented 8 years ago

Yeah let's fix it. I'll deal with wpcom merge headache next week. #70