{"size": 672, "ext": "js", "max_stars_repo_path": "index.js", "max_stars_repo_name": "alfonsorognoni/minesweeper", "max_stars_repo_stars_event_min_datetime": null, "max_stars_repo_stars_event_max_datetime": null, "max_issues_repo_path": "index.js", "max_issues_repo_name": "alfonsorognoni/minesweeper", "max_issues_repo_issues_event_min_datetime": "2021-03-10T00:58:03.000Z", "max_issues_repo_issues_event_max_datetime": "2021-05-10T20:36:32.000Z", "max_forks_repo_path": "index.js", "max_forks_repo_name": "alfonsorognoni/minesweeper", "max_forks_repo_forks_event_min_datetime": null, "max_forks_repo_forks_event_max_datetime": null}
{"max_stars_count": null, "max_issues_count": 2, "max_forks_count": null, "avg_line_length": 32.0, "max_line_length": 57, "alphanum_fraction": 0.712797619}
import Minesweeper from './minesweeper.js';
const game = new Minesweeper();
const modal = document.getElementById('modal');

const startButton = document.getElementById('btn-start');
const closeModal = document.getElementById('close');
startButton.addEventListener('click', event => {
    event.preventDefault();
    modal.style.display = 'none';
    game.start();
})
const restartButton = document.getElementById('restart');
restartButton.addEventListener('click', event => {
    event.preventDefault();
    modal.style.display = 'none';
    game.start();
})
closeModal.addEventListener('click', event => {
    event.preventDefault();
    modal.style.display = 'none';
})