How is CSR used to create custom view?

How is CSR used to create custom view?

CSR is a framework, but is not only used by developers to create custom view, it is also used for SharePoint itself in order to create custom views for different list types, for example if we take a look into SharePoint OOTB JS files we can see how the function RegisterTemplateOverrides is used in 20 files:

How to register custom templates in SharePoint 2013?

JSLink: is a way to attach a JavaScript file to a SharePoint Object. (JSLink attached to SPView could implement CSR or not). This post / article provides a detailed explanation about how works CSR internally in terms of overriding current templates and register out custom ones.

Which is the CSR core file in SharePoint?

We remarks clienttemplates.js as a Client Side Rendering framework core file, which is a SharePoint 2013 / SharePoint Online asset intended to implement all JavaScript logic of CSR. By default in SharePoint 2013 and Office 365 (Jan 2015), CSR core file is always loaded as it is shown in the picture:

What does CSR do to the HTML string?

So basically, what CSR does is it gets the JS object with raw data as input, and renders huge HTML string based on it: After HTML string is fully formed, it is inserted into the DOM. CSR processing of the raw data is divided into stages, each represented by one overridable JS function. Each function returns its own chunk of HTML.

How does CSR processing work in the Dom?

After HTML string is fully formed, it is inserted into the DOM. CSR processing of the raw data is divided into stages, each represented by one overridable JS function. Each function returns its own chunk of HTML. Stages are often nested into each other.

Is the CSR server side or client side?

Unlike previous SharePoint rendering systems (XSLT in 2010 and CAML in 2007), CSR is client-side. The only thing server-side webparts do is they put a huge bulk of raw data into the page, in JSON format.