Editing script files online in SharePoint editor and no syntax colouring

Andrew Black 0 Reputation points
2024-05-20T08:35:59.7466667+00:00

In the past week the scripts I have written that reside in a SharePoint library no longer open with syntax highlighting: colours, formatting, and code help.

I cannot see where settings changed - but now there is no highlighting. The scripts are displayed as plain text with some context menus, but no colours.

Has anyone else noticed this? Am I missing a setting?

Microsoft 365
Microsoft 365
Formerly Office 365, is a line of subscription services offered by Microsoft which adds to and includes the Microsoft Office product line.
4,069 questions
SharePoint
SharePoint
A group of Microsoft Products and technologies used for sharing and managing content, knowledge, and applications.
9,993 questions
SharePoint Development
SharePoint Development
SharePoint: A group of Microsoft Products and technologies used for sharing and managing content, knowledge, and applications.Development: The process of researching, productizing, and refining new or existing technologies.
2,754 questions
{count} votes

1 answer

Sort by: Most helpful
  1. RaytheonXie_MSFT 32,476 Reputation points Microsoft Vendor
    2024-05-21T06:23:16.7466667+00:00

    Hi @Andrew Black,

    It sounds like you're experiencing an issue with the display of scripts in SharePoint, where the syntax highlighting and formatting features are no longer working. This can be due to several reasons, including changes in SharePoint settings, updates, or browser-specific issues. Here are some steps you can take to troubleshoot and resolve this problem:

    1. Clear Cache and Cookies: Sometimes, browser cache and cookies can cause display issues. Clear your browser cache and cookies and then reload the SharePoint page.
    2. Disable Browser Extensions: Certain browser extensions can interfere with the display of SharePoint pages. Try disabling all extensions and see if the issue persists.
    3. Use a Different Browser: Test your SharePoint site in a different browser to determine if the issue is browser-specific.
    4. Ensure that the "Publishing Infrastructure" feature is activated on your SharePoint site. This can sometimes affect how scripts and pages are rendered.

    If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.