React Client Hints
npm install react-client-hints


React Client Hints Hooks, Component, and Provider. SSR-ready and fully unit-tested.
- React 16.8.0
- Provide simple API for latest Client Hints feature
- Using new React Context API
- SSR-ready
- Fully unit-tested
> Try it live at StackBlitz
``js
import React, { Component } from 'react';
import { render } from 'react-dom';
import { ClientHintsProvider, useClientHints } from 'react-client-hints';
const Hello = () => {
const ch = useClientHints();
return
const App = () => {
return (
);
};
render(
// SSR with compatible header object
const el = (
);
ReactDOMServer.renderToString(el);
``
MIT