Here's a tiny fix that removes a trailing comma in the `transformDirection` method. While it generally isn't an issue, it would break builds where we use terser (https://github.com/terser/terser) in strict 'es6' mode. Unlikely to cause any side-effects.