/minesweeper

Minesweeper game

Primary LanguageTypeScriptMIT LicenseMIT

Minesweeper game

Experience

Install and use

npm i minesweeper-game
import {Map} from 'minesweeper-game';

const map = new Map();

Reset Map

map.reset();

TS Statement

interface IMapOptions {
    width?: number; // Map size
    height?: number;
    tileSize?: number; // Tile size
    minesCount?: number;
    container?: HTMLElement | string;
}
declare class Map {
    constructor(options?: IMapOptions);
    config({ width, height, tileSize, minesCount, container, }?: IMapOptions, reset?: boolean): void;
    reset(): void;
}