Your F, defined on line 26 [0], is 3Hz off according to this reference table[1]. 346.23 should be 349.23. Just a typo?
All credit to @issa's ear. And yes, while you'd be unlikely to have encountered this bug if you were just telling a good existing synth to play an F, it's cool that you implemented the synth from scratch! Whether it's a good choice depends on the project goals.
[0] https://github.com/JNKKKK/pianochord.io/blob/master/src/libs...