import { Keyboard } from './inputs/keyboard'; import { Mouse } from './inputs/mouse'; export function createInput(key) { switch (key) { case 'keyboard': return Keyboard; break; case 'mouse': return Mouse; break; default: break; } }