memory board javascript