add hooks to view context