So Saturday, I'm moving my digital piano and literally had one of those "OMG there's a USB connection back here" moments. I chased an extra Type-B cable, plugged it into my laptop, downloaded the USB-Midi driver from Yamaha for macOS, found a suitable project to fork and created something in a couple hours.
It turns out that the Chrome browser has MIDIAccess now as a bleeding-edge feature, making this possible in client-side JavaScript.
The colorization matches that of my vexflow-syn project, in case you were wondering.
After my move this summer, I'd like to develop a realtime tablature app which takes advantage of both these projects at once.