add event emitter

add event emitter