On releasing v1.1––the internet was made for cats. I thought I was finished building Catcaller, but then it seemed like a good idea to add the possibility of filtering names based on sex. The list of names is just too long not to be split up into categories. Below is a snippet of my code.
It's a tad bit long, isn't it? And there's three separate functions––one for each filter option. It's a lot of repeat code, and I'm sure I could've put it all into one function, but I was struggling to get it to work properly. But that's what refactoring is for, right?
Ideally, the user would be able to select multiple filters at one time. But this generator does not work like that. Instead, after the user selects one of the three parameters, the other two are grayed out and disabled until the user deselects the current parameter. I plan to change that in a following update. What if the user wants to generate both male and female names at once? Male and neutral? Female and neutral?
I may want to try making an empty array and then adding both male and female names to it using
array.push(), or I could combine two lists using
array.concat(). I'll save that for another day.
Future update ideas 💡
- Add option to favorite names
- Add option to combine names
- Filter more than one parameter at a time
- Additional names
- UI changes
Bugs can be reported to firstname.lastname@example.org
Link to the repo can be found here
Please reach out with any questions, comments or suggestions