SP.View.jsLink property (sp.js)

Gets or sets the name of the JavaScript file used for the view.

Applies to: apps for SharePoint | SharePoint Foundation 2013 | SharePoint Server 2013

Note

The JSLink property is not supported on Survey or Events lists. A SharePoint calendar is an Events list.

var value = SP.View.get_jsLink ()
var value = SP.View.set_jsLink ()

Return value

Undefined

REST resource endpoint

See View resource for more information.

Endpoint URI structure

http://<sitecollection>/<site>/_api/web/lists(listid)/Views(viewid)/jsLink

HTTP requests

This resource supports the following HTTP commands:

  • POST

POST syntax

POST http://<sitecollection>/<site>/_api/web/lists(listid)/Views(viewid)/jsLink

GET syntax

GET http://<sitecollection>/<site>/_api/web/lists(listid)/Views(viewid)/jsLink