rofrischmann/fela

View on GitHub
benchmarks/ssr-comparison/src/simple-test/cases/aphrodite-no-important.js

Summary

Maintainability
A
3 hrs
Test Coverage
import { StyleSheet, css as aphroditeCss, StyleSheetServer, StyleSheetTestUtils } from 'aphrodite/no-important'
import { stylesheet } from '../styles'
import { renderHtml, renderBody } from '../render'

export const aphroditeNoImportantCase = caseName => {
  const useStyles = StyleSheet.create(stylesheet)

  const { html, css } = StyleSheetServer.renderStatic(() =>
    renderBody(caseName, aphroditeCss(useStyles.container), aphroditeCss(useStyles.button))
  )

  StyleSheetTestUtils.clearBufferAndResumeStyleInjection()

  return renderHtml(css.content, html)
}