JS mimicking a terminal with additional scripted writing capabilities.