@primer/react
Version:
An implementation of GitHub's Primer Design System using React
17 lines (13 loc) • 429 B
JavaScript
var React = require('react');
const BlankslateContext = /*#__PURE__*/React.createContext(null);
function useBlankslate() {
const context = React.useContext(BlankslateContext);
if (!context) {
throw new Error("useBlankslate must be used within a BlankslateProvider");
}
return context;
}
const Provider = BlankslateContext.Provider;
exports.Provider = Provider;
exports.useBlankslate = useBlankslate;
;