SOLVED

SharePoint framework react-script editor web part error

Copper Contributor

Hello Everyone

 

I tried to use Sharepoint react script editor web part and received below error.

 

***ERROR MESSAGE: ***Failed to load component "3a328f0a-99c4-4b28-95ab-fe0847f657a3" (ScriptEditorWebPart). Original error: ***Failed to load entry point from component "3a328f0a-99c4-4b28-95ab-fe0847f657a3" (ScriptEditorWebPart). Original error: Error loading https://component-id.invalid/3a328f0a-99c4-4b28-95ab-fe0847f657a3_0.0.1/office-ui-fabric-react as "office-ui-fabric-react" from https://component-id.invalid/3a328f0a-99c4-4b28-95ab-fe0847f657a3_0.0.1 Error loading https://component-id.invalid/3a328f0a-99c4-4b28-95ab-fe0847f657a3_0.0.1/office-ui-fabric-react Unable to load script https://publiccdn.sharepointonline.com/techmikael.sharepoint.com/11510075fe4212d19d3e6d07c91981263dd... ***CALLSTACK: Error: ***Failed to load component "3a328f0a-99c4-4b28-95ab-fe0847f657a3" (ScriptEditorWebPart). Original error: ***Failed to load entry point from component "3a328f0a-99c4-4b28-95ab-fe0847f657a3" (ScriptEditorWebPart). Original error: Error loading https://component-id.invalid/3a328f0a-99c4-4b28-95ab-fe0847f657a3_0.0.1/office-ui-fabric-react as "office-ui-fabric-react" from https://component-id.invalid/3a328f0a-99c4-4b28-95ab-fe0847f657a3_0.0.1 Error loading https://component-id.invalid/3a328f0a-99c4-4b28-95ab-fe0847f657a3_0.0.1/office-ui-fabric-react Unable to load script https://publiccdn.sharepointonline.com/techmikael.sharepoint.com/11510075fe4212d19d3e6d07c91981263dd... at Anonymous function (https://localhost:4321/node_modules/@microsoft/sp-loader/dist/sp-loader_en-us.js:16234:9) at lib$es6$promise$$internal$$tryCatch (https://localhost:4321/node_modules/@microsoft/sp-loader/dist/sp-loader_en-us.js:21064:9) at lib$es6$promise$$internal$$invokeCallback (https://localhost:4321/node_modules/@microsoft/sp-loader/dist/sp-loader_en-us.js:21076:9) at lib$es6$promise$$internal$$publish (https://localhost:4321/node_modules/@microsoft/sp-loader/dist/sp-loader_en-us.js:21047:11) at lib$es6$promise$$internal$$publishRejection (https://localhost:4321/node_modules/@microsoft/sp-loader/dist/sp-loader_en-us.js:20997:7) at lib$es6$promise$asap$$flush (https://localhost:4321/node_modules/@microsoft/sp-loader/dist/sp-loader_en-us.js:20822:9)

 

Any Suggestion?

 

13 Replies
best response confirmed by arvinditku3018 (Copper Contributor)
Solution

You're trying to load artefacts from https://publiccdn.sharepointonline.com/techmikael.sharepoint.com/ - AFAIK that is the SharePoint tenant of Mikael Svensson, and not you :)

 

Modify the config/config.json to point to YOUR location where you have your Office UI Fabric React components

Thanks Wictor. :)

I noticed that, but later I thought it would be some public cdn so I can access.
Now it is confirmed. Will give a try again.

Well, it should work just fine loading from the CDN of a different tenant. I’ll do a PR and revert back to local bundling of the fabric. And might upgrade to latest drop as well.

I have now updated the code. The PR is at https://github.com/SharePoint/sp-dev-fx-webparts/pull/321, and the complete sample is in my dev branch until merged - https://github.com/wobba/sp-dev-fx-webparts/tree/RemoveCDN/samples/react-script-editor

 

The updated removes all external references, bundling everything needed in the part it self. Also update it to drop v1.3.

Hi Mikael, can this web part be run on SharePoint 2019 on-prem? By on-prem in this case there are no internet connection.

I get the webpart running on my dev laptop in workbench. But when building a package an deploying it to the on-prem environment. I get a lot of errors on the webpart. Failed to load manifest and so on...

I'm just starting experimenting with spfx, and trying to implement your webpart in my companys dev environment.

The error output is:

SPLoaderError.loadComponentError]:
***Failed to load component "3a328f0a-99c4-4b28-95ab-fe0847f657a3" (ScriptEditorWebPart).
Original error: ***Manifest not found for component id "974a7777-0990-4136-8fa6-95d80114c2e0" and version "1.5.1".

***INNERERROR:
***Manifest not found for component id "974a7777-0990-4136-8fa6-95d80114c2e0" and version "1.5.1".
***CALLSTACK:
Error
at t._generateErrorStackForIE (http://sharepointsite.x.xxx/_layouts/15/next/spclient/en-us/sp-pages-assembly.js?uniqueId=2g4QD:356:...)
at t (http://sharepointsite.x.xxx/_layouts/15/next/spclient/en-us/sp-pages-assembly.js?uniqueId=2g4QD:356:...)
at t (http://sharepointsite.x.xxx/_layouts/15/next/spclient/en-us/sp-pages-assembly.js?uniqueId=2g4QD:807:...)
at e.buildErrorWithVerboseLog (http://sharepointsite.x.xxx/_layouts/15/next/spclient/en-us/sp-pages-assembly.js?uniqueId=2g4QD:807:...)
at e.buildLoadComponentError (http://sharepointsite.x.xxx/_layouts/15/next/spclient/en-us/sp-pages-assembly.js?uniqueId=2g4QD:807:...)
at Anonymous function (http://sharepointsite.x.xxx/_layouts/15/next/spclient/en-us/sp-pages-assembly.js?uniqueId=2g4QD:807:...)
at A (http://sharepointsite.x.xxx/_layouts/15/next/spclient/10.sp-pages-search.js:8:1743)
at k (http://sharepointsite.x.xxx/_layouts/15/next/spclient/10.sp-pages-search.js:8:1831)
at Anonymous function (http://sharepointsite.x.xxx/_layouts/15/next/spclient/10.sp-pages-search.js:8:5649)
at h (http://sharepointsite.x.xxx/_layouts/15/next/spclient/10.sp-pages-search.js:8:344)

 

Hi,

You probably need to downgrade @Pernille-Eskebo npm packages to ~1.1.0 and possibly edit tsconfig.json and .yo-rc.json. If you create a dummy SPFx 2016 part - and copy the configs you should be able to get it working.

 

Guess I could do the work myself - but don't have any on-prem environments to test on :) If you create a PR which updates to SPFx v1.7.1 and changes lib compat to online as well I'll merge it.

I too received the error mentioned above. Sorry to bother, I'm new to this - so any help would be appreciated!
I suggest pulling down the latest dev branch and rebuild from github. And please log issues at github and not here. Easier to track :)
..and the part is made for online. Onprem requires an effort.

@Mikael Svenson

Hi again Mikael, just wanted to tell you I got your webpart working in SharePoint 2019 on-prem (offline)

Seems the biggest issue is that when you create a project with the React Framework, it uses version 16.x.x of React which 2019 does not support. Downgrading to a version of the 15 release did the trick.

@Hans Kristian Kristoffersen feel free to do a PR, and I'll happily downgrade to make it work more places.

 

Then again - DON'T USE this web part! :D

@Hans Kristian Kristoffersen 

I have the same issue and verified the version of React in my config file is 15.6.6 but still the exact same issue.

Failed to load component "3a328f0a-99c4-4b28-95ab-fe0847f657a3" (ScriptEditorWebPart).
Original error: ***Manifest not found for component id "974a7777-0990-4136-8fa6-95d80114c2e0" and version "1.5.1"

Here is my package.json file:

 

1 best response

Accepted Solutions
best response confirmed by arvinditku3018 (Copper Contributor)
Solution

You're trying to load artefacts from https://publiccdn.sharepointonline.com/techmikael.sharepoint.com/ - AFAIK that is the SharePoint tenant of Mikael Svensson, and not you :)

 

Modify the config/config.json to point to YOUR location where you have your Office UI Fabric React components

View solution in original post