This example shows how Redactor X can add predefined classes to all specified tags. You can see the result by clicking on the source code button on the toolbar.
<!DOCTYPE html>
<html>
<head>
<title>Redactor X</title>
<meta charset="utf-8">
<!-- css -->
<link rel="stylesheet" href="/your-dist-path/redactorx.min.css" />
</head>
<body>
<!-- element -->
<textarea id="entry">...</textarea>
<!-- js -->
<script src="/your-dist-path/redactorx.min.js"></script>
<!-- call -->
<script>
RedactorX('#entry', {
classes: {
'p': 'my-paragraph',
'h2': 'my-heading'
}
});
</script>
</body>
</html>