Skip to content

DynamicScriptMiddleware class

namespace: Serenity.Web.Middleware   assembly: Serenity.Net.Web

Dynamic script middleware that handles /DynJS.axd/ and /DynamicData/ paths.

public class DynamicScriptMiddleware
parameter description
next The next request delegate.

Public Members

name description
DynamicScriptMiddleware(…) Dynamic script middleware that handles /DynJS.axd/ and /DynamicData/ paths.
Invoke(…) Invokes the middleware in the given context.
static ReturnScript(…) Returns a dynamic script by its key. A missing script gets a 404 response. A script the user may not access gets a 403 response if the user is logged in, and the same 404 response as a missing script otherwise, so that an anonymous visitor can't tell which script keys (e.g. forms and lookups) exist.
static WriteWithIfModifiedSinceControl(…) Writes file content to the response with If-Modified-Since control.

Remarks

Initializes a new instance of the DynamicScriptMiddleware class.

See Also