grouped scope and state in an options object