{"size": 755, "ext": "js", "max_stars_repo_path": "demo.js", "max_stars_repo_name": "lazurite-app/launch-control-xl", "max_stars_repo_stars_event_min_datetime": "2016-01-31T08:38:28.000Z", "max_stars_repo_stars_event_max_datetime": "2021-04-28T20:59:37.000Z", "max_issues_repo_path": "demo.js", "max_issues_repo_name": "lazurite-app/launch-control-xl", "max_issues_repo_issues_event_min_datetime": "2016-08-15T19:55:27.000Z", "max_issues_repo_issues_event_max_datetime": "2016-08-18T14:11:48.000Z", "max_forks_repo_path": "demo.js", "max_forks_repo_name": "lazurite-app/launch-control-xl", "max_forks_repo_forks_event_min_datetime": "2016-08-23T14:12:51.000Z", "max_forks_repo_forks_event_max_datetime": "2017-07-19T15:14:02.000Z"}
{"max_stars_count": 8, "max_issues_count": 1, "max_forks_count": 3, "avg_line_length": 25.1666666667, "max_line_length": 65, "alphanum_fraction": 0.6132450331}
import LaunchControlXL from './'

navigator.requestMIDIAccess({
  sysex: true
}).then(midi => {
  ;[1, 2, 3, 4, 5, 6, 7, 8].forEach(bank => {
    const controller = new LaunchControlXL({ bank })

    for (var input of midi.inputs.values()) {
      controller.setInput(input)
    }
    for (var output of midi.outputs.values()) {
      controller.setOutput(output)
    }

    controller.reset()
    controller.on('input', function (...data) {
      console.log('input', data)
    })
    controller.on('output', function (...data) {
      console.log('output', data)
    })

    setInterval(function () {
      controller.outputs.buttons[0] = controller.inputs.faders[0]
      controller.outputs.buttons[1] = controller.inputs.faders[1]
    }, 250)
  })
})
