Allow the user to define defaults for actions and listeners

Also standardized how configuration is handled
Fix tests for new defaults() api