[javascript-astar] Fix typo in Heuristics (#30450)

* [javascript-astar] Fix typo in Heuristic types

* [javascript-astar] Add @lazerwalker to header
This commit is contained in:
Mike 2018-11-15 03:19:38 +01:00 committed by Pranav Senthilnathan
parent 45facea70c
commit b8cb5dc065
2 changed files with 3 additions and 3 deletions

View File

@ -1,6 +1,6 @@
// Type definitions for javascript-astar
// Project: https://github.com/bgrins/javascript-astar
// Definitions by: brian ridley <https://github.com/ptlis>
// Definitions by: brian ridley <https://github.com/ptlis>, Mike Lazer-Walker <https://github.com/lazerwalker>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
declare class Graph {
@ -18,7 +18,7 @@ interface Heuristic {
}
interface Heuristics {
manhatten: Heuristic;
manhattan: Heuristic;
diagonal: Heuristic;
}

View File

@ -18,7 +18,7 @@ function test_search_returns_nodes() {
}
function test_search_alternative_heuristic() {
let nodes: Array<GridNode> = astar.search(new Graph([]), {x: 1, y: 1}, {x: 2, y: 2}, {heuristic: astar.heuristics.manhatten});
let nodes: Array<GridNode> = astar.search(new Graph([]), {x: 1, y: 1}, {x: 2, y: 2}, {heuristic: astar.heuristics.manhattan});
}
function test_search_or_closest() {