Seriously.js
Seriously.js copied to clipboard
Fix enum display in index example
This should fix not shown enums in the index.html example in drop down menus.
Thanks for submitting this. Generally looks good, but a few style nitpicks:
-
Please declare
singleOption
as part of thevar
statement at the top of the function with the rest of the variables. (I may reconsider this style choice in the future, especially if I migrate to ES6let
andconst
. But I'd like to keep it consistent for now.) -
Please do a
hasOwnProperty
check inside the for...in loop? -
option.value = singleOption;
is repeated unnecessarily. It can be placed once outside theif
branch.
Thanks, B
Thanks for the feedback. I hopefully interpreted 2) correctly.