PostProcessing content?

Can we use PostProcess to perform content transformations like characters replacements in every public/**/*.html files ?

For example to move a task like that from Gulp to Hugo building process:

function html() {
  return src('public/**/*.html')
    .pipe(replace('« ', '« '))
    .pipe(replace(' »', ' »'))
    .pipe(beautify({
      indent_size: 2,
      preserve_newlines: false,
      extra_liners: []
    }))
    .pipe(dest('public'))
}

Theoretically yes. Check the purgecss sample here:

You probably have to define html() as a (javascript) module (not a Hugo module) and could use it in place of the purgecss-constant.