add else snippet for views