Make view_counter use the corrent scope for its state