Port height module to plugin

This commit is contained in:
Adam Wathan 2019-01-09 21:16:16 -05:00
parent c8802df40d
commit 964bf81ee3
4 changed files with 15 additions and 16 deletions

13
src/plugins/height.js Normal file
View file

@ -0,0 +1,13 @@
import _ from 'lodash'
export default function () {
return function ({ addUtilities, config, e }) {
const utilities = _.fromPairs(_.map(config('height'), (value, modifier) => {
return [`.${e(`h-${modifier}`)}`, {
'height': value,
}]
}))
addUtilities(utilities, config('modules.height'))
}
}