refactor how data params are applied to options

I would argue that applying the options set througth `data-` params in this way is a little more maintainble.