12.0.3 • Published 4 years ago

@fela-next/fela-layout-debugger v12.0.3

Weekly downloads
-
License
MIT
Repository
github
Last release
4 years ago

fela-layout-debugger

Uses styles-debugger to add outlines and labels to every rule component. This helps to debug the application layout. Same rules will always have the same color.

Installation

yarn add fela-layout-debugger

You may alternatively use npm i --save fela-layout-debugger.

Usage

import { createRenderer } from '@fela-next/fela'
import layoutDebugger from '@fela-next/fela-layout-debugger'

const renderer = createRenderer({
  enhancers: [ layoutDebugger() ]
})

Configuration

Options

It takes an options object with the shape of the official styles-debugger configuration options.

Example
import { createRenderer } from '@fela-next/fela'
import layoutDebugger from '@fela-next/fela-layout-debugger'

const layoutDebuggerEnhancer = layoutDebugger({
	pseudoElement: 'before',
	color: 'red',
	borderSize: 3,
	position: 3
})

const renderer = createRenderer({
  enhancers: [ layoutDebuggerEnhancer ]
})

License

Fela is licensed under the MIT License. Documentation is licensed under Creative Common License. Created with ♥ by @robinweser and all the great contributors.

12.0.3

4 years ago

12.0.2

4 years ago

12.0.1

4 years ago