UNPKG

phaser-jsx

Version:
16 lines 666 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.useRef = useRef; /** * A hook that lets you reference a value that’s not needed for rendering. * * @param initialValue - The value you want the ref object’s current property to be initially. It can be a value of any type. This argument is ignored after the initial render. * @returns - Returns an object with a single property `current` (initially set to the `initialValue` you have passed). */ function useRef(initialValue) { if (initialValue === void 0) { initialValue = null; } return { current: initialValue, }; } //# sourceMappingURL=useRef.js.map