This example shows how to move a toolbar button into the extrabar.
<div id="entry-move-to-extrabar"></div>
const app = Redactor('#entry-move-to-extrabar', {
toolbar: {
hide: ['source']
},
extrabar: {
add: {
source: true
}
}
});