More work done on events.
Added hooks to components and context.