UNPKG

phaser-jsx

Version:
18 lines 447 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.attachRef = attachRef; /** * Attaches game object ref. * * @param gameObject - Phaser game object. * @param ref - Ref callback. */ function attachRef(gameObject, ref) { if (typeof ref === 'function') { ref(gameObject); } else if (ref && typeof ref === 'object') { ref.current = gameObject; } } //# sourceMappingURL=ref.js.map