make the data-attribute api optional, and enabled via method