adds method and view for snippets#index