0.1.0 • Published 6 years ago
dedent.macro v0.1.0
dedent.macro
A babel macro for dedent
Usage
Setting up babel macros
yarn add babel-plugin-macros
.babelrc
{
"plugins": ["macros"]
}
See more info in the main documentation
Setting up dedent.macro
yarn add --dev dedent.macro
import dedent from 'dedent.macro'
dedent`
hi there
this is fine
`
This will transform out the leading spaces, just like regular Dedent usage would, but with the difference being that the dedent call will be transformed out completely during the babel process.
0.1.0
6 years ago