import { StrictMode } from 'react'; import ReactDOM from 'react-dom'; import { useHMetrics, withFontManager } from '../../font'; import { FontProvider } from '../../font/FontProvider'; import '../style/fonts.css'; withFontManager( fontManager => void ReactDOM.render( , document.getElementById('root'), ), ); function App() { const { width } = useHMetrics({ fontFamily: 'Roboto', fontSize: 16, text: 'Hello World', }); return
Hello World 16px width: {width.toFixed(1)}px
; }