Skip to content

Commit a71f055

Browse files
committed
moved note about .display() only working in a html document to top of .display() section and also mentioned that there needs to be a canvas element
1 parent 2978e08 commit a71f055

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

README.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,11 +75,13 @@ Returns the finished maze
7575

7676
This is the function which displays the maze.
7777

78+
_Note that this function (currently) only works in a html document with a canvas element._
79+
7880
It takes in an object with the properties listed below.
7981

8082
| Property | Description | Valid Values | Default Value |
8183
|-|-|-|-|
82-
| canvas | The canvas to display the maze on. | A canvas element (e.g. `document. getElementsByTagName("canvas")[0]`). | The first canvas element in the html. [Note that this function (currently) only works in a html document.] |
84+
| canvas | The canvas to display the maze on. | A canvas element (e.g. `document. getElementsByTagName("canvas")[0]`). | The first canvas element in the html. |
8385
| coloringMode | How the cells are colored. | `"normal"`: regular coloring, `"distance"`: each cell is colored by a distance from a point (WIP). More coloring modes coming soon hopefully. Anything other than the valid values specififed defaults to normal coloring. | `"normal"` |
8486
| colorScheme | The color scheme to use when `coloringMode` is not `"normal"`. | This can either be `"grayscale"`, `"rainbow"` or an array or hex codes. | `"rainbow"` |
8587
| mainColor | This is the color of the walls (or line). | Any hex value as a string | `"#000"` |

0 commit comments

Comments
 (0)