Add initBefore plugin method