Simple minesweeper with javascript