UNPKG

create-expo-cljs-app

Version:

Create a react native application with Expo and Shadow-CLJS!

11 lines (9 loc) 270 B
import React from 'react'; import AnimatedValue from './core/AnimatedValue'; export default function useValue(initialValue) { const ref = React.useRef(null); if (ref.current === null) { ref.current = new AnimatedValue(initialValue); } return ref.current; }