Combine class and id selector rule to create a new class selector.
A simple module to combine two or more selectors into a single selector and return the selector of the new class. This could be used to reduce the amount of classes applied to a element, or to create a random class name on each page load to make it more difficult for aggregators.
window.selectorFactory = require("selector_factory");
npm i selector_factory
Combine
window.selectorFactory.combine([".text-primary",".bg-primary"]).then(function(data){ data.newSelectorName; // holds the newly created class name });