Middleware to destroy caching. Latest version: 4.0.0, last published: 2 years ago. Start using nocache in your project by running `npm i nocache`. There are 529 other projects in the npm registry using nocache., The nocache tool tries to minimize the effect an application has on the Linux file system cache. This is done by intercepting the open and close system calls and calling posix_fadvise with the POSIX_FADV_DONTNEED parameter. Because the library remembers which pages (ie., 4K-blocks of the file) were already in file system cache when the file was opened, these will not be marked as "don't need , The Cache-Control header is used to specify directives for caching mechanisms in both HTTP requests and responses.. A typical header looks like this Cache-Control: public, max-age=10. public Indicates that the response may be cached by any cache. private Indicates that the response is intended for a single user and must not be stored by a shared cache., Under certain circumstances, IE6 will still cache files even when Cache-Control: no-cache is in the response headers.. The W3C states of no-cache:. If the no-cache directive does not specify a field-name, then a cache MUST NOT use the response to satisfy a subsequent request without successful revalidation with the origin server., By adding Cache-Control: no-cache to the response along with Last-Modified and ETag — as shown below — the client will receive a 200 OK response if the requested resource has been updated, or will otherwise receive a 304 Not Modified response if the requested resource has not been updated. http. HTTP/1.1 200 OK Content-Type: text/html , no-cache If the no-cache directive does not specify a field-name, then a cache MUST NOT use the response to satisfy a subsequent request without successful revalidation with the origin server. This allows an origin server to prevent caching even by caches that have been configured to return stale responses to client requests..