GoScrobble/web/node_modules/@material-ui/styles/useTheme/useTheme.js

23 lines
580 B
JavaScript
Raw Normal View History

2022-04-25 02:47:15 +00:00
"use strict";
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.default = useTheme;
var _react = _interopRequireDefault(require("react"));
var _ThemeContext = _interopRequireDefault(require("./ThemeContext"));
function useTheme() {
var theme = _react.default.useContext(_ThemeContext.default);
if (process.env.NODE_ENV !== 'production') {
// eslint-disable-next-line react-hooks/rules-of-hooks
_react.default.useDebugValue(theme);
}
return theme;
}