refactor(pack): add event emitter support in pack module