A function of your own

`goalMarkup` is given where each goal stands and returns SVG in feet.

NHL hockey rinkDrawn as: an ice hockey rink, 200 by 85 feet with rounded corners, with its red and blue lines, face-off circles, creases and goal nets.

The picture above was drawn when the docs were built. The script below draws it again with the published package.

import { drawKyogijo } from "@johnmorrisdotca/kyogijo-stadiums";

const svg = drawKyogijo({
  sport: "nhl",
  goalMarkup: ({ x, y, width, out }) => '<rect x="' + (out < 0 ? x - 4 : x) + '" y="' + (y - width / 2) + '" width="4" height="' + width + '" fill="#1d4f91"/>',
});

This page imports the package from jsDelivr (major version 0), which serves only versions that have been published to npm. A feature added after the last release is not in it: the page then keeps the picture above and says why. The docs were built from version 0.6.1.