import { colorSchemes } from 'core/colors' ; param { String } content returns { String } example export function tokenize ( content ) { const tokenizedContent = Object . entries ( colorSchemes . dark ) . reduce ( ( acc , [ key , value ] ) => { const captureHexColors = new RegExp ( `${ value }` , 'g' ) ; acc = acc . replace ( captureHexColors , `{{ ${ key } }}` ) ; return acc ; } , content ) ; return tokenizedContent ; }