@filbert-js/style-sheet-context
Version:
> StyleSheet Context for filbert-js
2 lines (1 loc) • 574 B
JavaScript
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("react"),require("@filbert-js/browser-stylesheet")):"function"==typeof define&&define.amd?define(["exports","react","@filbert-js/browser-stylesheet"],t):t(e.styleSheetContext={},e.react,e.browserStylesheet)}(this,function(e,t,r){t=t&&t.hasOwnProperty("default")?t.default:t,e.__sheet=r.createStylesheet();var s=t.createContext(e.__sheet);e.StyleSheetContext=s,e.StyleSheetProvider=function(r){var o=r.stylesheet,n=r.children;return e.__sheet=o,t.createElement(s.Provider,{value:o},n)}});