UNPKG

react-themable-hoc-jss-interface

Version:
14 lines (11 loc) 344 B
import { create } from 'jss'; export default class JSSInterface { constructor(jss = create(), options = {}) { this.jss = jss; this.options = options; } css(styles) { const styleSheet = this.jss.createStyleSheet(styles, this.options).attach(); return { ...styleSheet.classes }; } }