About me: software developer who is into JavaScript and NodeJS and constantly working on one or another side project and/or open source. I have a blog at https://alex-rudenko.com
You can try to use singular form only for consistency and if you have a collection of objects use a prefix or suffix indicating that this is a collection: e.g. productList, productArray, l_product, a_product. I don't like this that much but also I would try to avoid bad English. Perhaps what can also help is to use only words which have simple s ending in the plural form, for example, instead of inventory use inventoryItem which becomes inventoryItems
It's funny I've done this many times for projects in the past, as a habit I picked up from Backbone.js where their convention is to append model names with "_collection" (so "product" becomes "product_collection"), yet it didn't occur to me this time around. It's horrifying how taking over legacy projects can screw with ones mind...
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
You can try to use singular form only for consistency and if you have a collection of objects use a prefix or suffix indicating that this is a collection: e.g. productList, productArray, l_product, a_product. I don't like this that much but also I would try to avoid bad English. Perhaps what can also help is to use only words which have simple
s
ending in the plural form, for example, instead ofinventory
useinventoryItem
which becomesinventoryItems
It's funny I've done this many times for projects in the past, as a habit I picked up from Backbone.js where their convention is to append model names with "_collection" (so "product" becomes "product_collection"), yet it didn't occur to me this time around. It's horrifying how taking over legacy projects can screw with ones mind...