Skip to content

Commit 9caed19

Browse files
committed
article describing modern opt out for lists and libraries
1 parent 2bc5c1f commit 9caed19

File tree

2 files changed

+89
-0
lines changed

2 files changed

+89
-0
lines changed
Loading
Lines changed: 89 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,89 @@
1+
---
2+
title: Opting out of the modern list and library experience
3+
description: Explains how to correctly opt out from modern list and libraries
4+
ms.date: 12/21/2018
5+
ms.prod: sharepoint
6+
---
7+
8+
# Opting out of the modern list and library experience
9+
10+
In 2016, we introduced a new “modern” experience for SharePoint, bringing extensibility, accessibility, and responsive design to a complete overhaul of the user experience. Since then, modern has been the basis for innovation throughout SharePoint and OneDrive, although classic mode remains supported and available. Although the majority of lists and libraries work perfect in the modern experience, there are also lists which don't work as expected or miss functionality when used in modern. Often this is due to customizations on the list (e.g. JSLink) or on the list form page (e.g. multiple web parts used). SharePoint will detect most incompatible customizations and will at present the impacted lists and libraries using the classic experience, while the other lists and libraries in the site will work using the modern experience. If switching between the modern and classic experiences is not acceptable then you do have the option to opt out lists and libraries from the modern experience. In this article you'll learn about the available opt out options, how to detect lists and libraries that could benefit from opting out of modern and finally how to best handle the opt out.
11+
12+
## Options to opt out lists and libraries from the modern experience
13+
14+
### Opting out at site collection level
15+
16+
You can opt out a site collection from using the "modern" experience by enabling a feature with ID **E3540C7D-6BEA-403C-A224-1A12EAFEE4C4**. Use the following [PnP PowerShell](http://aka.ms/sppnp-powershell) to enable/disable the needed feature:
17+
18+
```powershell
19+
# Connect to a site
20+
$cred = Get-Credential
21+
Connect-PnPOnline -Url https://[tenant].sharepoint.com/sites/siteurl -Credentials $cred
22+
23+
# Prevent modern lists and libraries at site collection level
24+
Enable-PnPFeature -Identity E3540C7D-6BEA-403C-A224-1A12EAFEE4C4 -Scope Site
25+
# And again enable modern lists and libraries at site collection level
26+
#Disable-PnPFeature -Identity E3540C7D-6BEA-403C-A224-1A12EAFEE4C4 -Scope Site
27+
```
28+
29+
### Opting out at web level
30+
31+
You can opt out a web from using the "modern" experience by enabling a feature with ID **52E14B6F-B1BB-4969-B89B-C4FAA56745EF**. Use the following [PnP PowerShell](http://aka.ms/sppnp-powershell) to enable/disable the needed feature:
32+
33+
```powershell
34+
# Connect to a site
35+
$cred = Get-Credential
36+
Connect-PnPOnline -Url https://[tenant].sharepoint.com/sites/siteurl -Credentials $cred
37+
38+
# Prevent modern lists and libraries at web level
39+
Enable-PnPFeature -Identity 52E14B6F-B1BB-4969-B89B-C4FAA56745EF -Scope Web
40+
# And again enable modern lists and libraries at web level
41+
#Disable-PnPFeature -Identity 52E14B6F-B1BB-4969-B89B-C4FAA56745EF -Scope Web
42+
```
43+
44+
### Opting out at list level
45+
46+
To control the experience at the library level, you can go to **List settings** > **Advanced settings**, and change the behavior.
47+
48+
**List experience configuration in the SharePoint tenant level settings in Admin UI**
49+
50+
![List experience configuration in the SharePoint tenant level settings in Admin UI](media/modernize/list-experience-setting.png)
51+
52+
The same can also be done by using [PnP PowerShell](http://aka.ms/sppnp-powershell) as shown in this snippet:
53+
54+
```powershell
55+
# Connect to a site
56+
$cred = Get-Credential
57+
Connect-PnPOnline -Url https://[tenant].sharepoint.com/sites/siteurl -Credentials $cred
58+
59+
# Get the list to update
60+
$list = Get-PnPList -Identity "Shared Documents" -Includes ListExperienceOptions
61+
62+
# Set the list experience (0 = Auto, 1 = modern, 2 = classic)
63+
$list.ListExperienceOptions = 2
64+
$list.Update()
65+
Invoke-PnPQuery
66+
```
67+
68+
> [!NOTE]
69+
> - The settings at the library level *override* the settings at the web or site collection level.
70+
71+
## How to detect lists and libraries that are candidates for being opted out of the modern experience
72+
73+
Opting out of the modern experience is only needed in certain cases, as described in this article's introduction. Previous chapter showed you how to perform an opt out, but how do know which lists and libraries are candidates to be opted out from the modern experience?
74+
75+
The [SharePoint Modernization scanner](https://aka.ms/sppnp-modernizationscanner) will give you the needed answers: if you run the scanner in "Full scan" or in "Modern list experience readiness" mode the scanner will collect all the data about your lists. Using the generated **Modern UI List Readiness** Excel report you can find the lists having customizations as explain in the [Analyze and use the scanner data](modernize-userinterface-lists-and-libraries-scanner.md) article.
76+
77+
The found lists will already present themselves in classic, due to SharePoint's classic fallback mechanism. If you however want to offer a full classic user experience than you might want to opt out the complete site collection from modern lists and libraries. To help you with that the scanner generates a CSV file named **SitesWithCustomizations.csv**. This CSV file is simple list of site collection URL's without a header as shown in below sample:
78+
79+
```text
80+
"https://contoso.sharepoint.com/sites/siteA"
81+
"https://contoso.sharepoint.com/sites/siteB"
82+
"https://contoso.sharepoint.com/sites/siteC"
83+
```
84+
85+
## How to best handle the opt out of the selected site collections
86+
87+
You can use the earlier described options to opt out a list, web or site collection from modern lists and libraries. If you've used the scanner to generate a list of site collections that are candidates for being opted out of modern, you then can use below [PnP PowerShell script](https://github.com/SharePoint/sp-dev-modernization/tree/master/Scripts/ListsAndLibraries) to perform a "bulk" opt out.
88+
89+
[!code-powershell[bulklistoptout](../../sp-dev-modernization/Scripts/ListsAndLibraries/SetModernListUsage.ps1 "Bulk site opt out of modern lists and libraries")]

0 commit comments

Comments
 (0)