Is there an alternative to the Outputcache directive previously used on . aspx pages, to be used on . cshtml pages in . net core?

Asked

Viewed 31 times

0

Is there an alternative to the Outputcache directive previously used on . aspx pages, to be used on . cshtml pages in Asp . net core ?

1 answer

1


In ASP.NET Core you have two options in this cache strategy that you are looking for.

  1. The attribute Responsecache that you can apply only to actions that return data to the View. Thus, all elements of the View that are loaded from the return of Actions, will be retrieving this cache return.

  2. Cache Tag Helper where all the content in your .cshtml that is inside the tag <cache>, will be being stored in cache.

  • Great, thank you Raquel Pinheiro!

  • For nothing @Ronaldosampaio, until next time.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.