Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

usefloc

catminusminus18MIT0.1.4TypeScript support: included

React Hook to use FLoC API

yarn add usefloc

react, react hook, floc

readme

useFLoC

React Hook to use FLoC API

yarn add usefloc

Example

import * as React from 'react';
import { useFLoC } from 'usefloc';

const App = () => {
  const {id, version} = useFLoC();
  return (
    <div>
      id: {id}, version: {version}
    </div>
  );
};