Windows 10 : JavaScript runtime error

Sep 6, 2015 at 6:40 PM
Hi Team

I am trying to integrate Google Analytics SDK with WinJS UWP Windows 10 App.

I have successfully added the reference and manually included the analytics.xml file. However on running the app I am getting the error "JavaScript runtime error: The specified module could not be found."
Coordinator
Sep 10, 2015 at 4:17 PM
Are you using the NuGet package or the vsix installer? analytics.xml is only needed for the NuGet package but I wanted to make sure. Fyi, the vsix is recommended for JS apps but both options should work. There's a brief explanation on the Getting Started (JavaScript apps) page about this.
Sep 29, 2015 at 5:37 AM
Hi infinitydlimit,

Were you able to solve this problem? If Yes, can you please help us resolving this. I am getting the same issue with my JS app.
Oct 6, 2015 at 11:55 AM
Hi timgreenfield,

I am not able to use this SDK in WinJS Windows 10 app. can you please help me through this??

Thanks
Nov 18, 2016 at 10:10 PM
To make it work you need to plug NuGet package version 1.3.1, then open .jsproj file and manually delete two xml elements for each GoogleAnalyticsSDK reference
 <CopyLocal>True</CopyLocal>
 <SpecificVersion>True</SpecificVersion>
Related NuGet issue is here: https://github.com/NuGet/Home/issues/2406#issuecomment-242569851

Due to SpecificVersion element, WinJS/UWP project can't resolve assembly reference correctly and thus you are getting the js error.