Skip to content

amir-ziaei/Minesweeper

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

27 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Online Demo

Here you can find the online demo of the game.

How to Use

Link script.bundle.js to your HTML file.

<script src="src/js/script.bundle.js"></script>

Then later:

<div
  class="minesweeper"
  data-width="10"
  data-height="10"
  data-difficulty="normal"
  data-debug="false"
></div>

Attributes:

  • class: must include minesweeper

  • data-width: int - Number of rows

  • data-height: int - Number of columns

  • data-difficulty: String - Affects the number of mines distributed on the map

    • easy about 10% of squares will be mines

    • normal about 15% of squares will be mines

    • hard about 20% of squares will be mines

  • data-debug: Boolean - Mines will be shown

About

Classic minesweeper JS implementation

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published