0

I'm building a responsive website from the ground up for use as a SharePoint 2013 masterpage, using skel.js to control the grid and breakpoints. Once published, the js files (skel.min.js, skel-panels.min.js, jquery.min.js, html5shiv.js, and a simple config.js written by me to configure skel and skel-panels) do not reliably run every time a user hits the site, leaving the CSS frozen at whatever breakpoint the browser matched at the time. A refresh usually fixes the issue, but that's not an acceptable solution. So far this happens in IE, Chrome and FF (all versions that don't trigger html5shiv).

<!--SPM:<SharePoint:ScriptLink language="javascript" ID="scriptLink1" name="~SiteCollection/Style Library/js/jquery.min.js" runat="server" Localizable="false"/>-->
<!--SPM:<SharePoint:ScriptLink language="javascript" ID="scriptLink2" name="~SiteCollection/Style Library/js/skel.min.js" runat="server" Localizable="false"/>-->
<!--SPM:<SharePoint:ScriptLink language="javascript" ID="scriptLink3" name="~SiteCollection/Style Library/js/skel-layers.min.js"  runat="server" Localizable="false"/>-->
<!--SPM:<SharePoint:ScriptLink language="javascript" ID="scriptLink4" name="~SiteCollection/Style Library/js/jquery.dropotron.min.js"  runat="server" Localizable="false"/>-->
<!--SPM:<SharePoint:ScriptLink language="javascript" ID="scriptLink5" name="~SiteCollection/Style Library/js/jquery.scrolly.min.js"  runat="server" Localizable="false"/>-->
<!--SPM:<SharePoint:ScriptLink language="javascript" ID="scriptLink10" name="~SiteCollection/Style Library/js/init.js" runat="server" Localizable="false"/>-->

Please help, I have been struggling to get right since last few days.

Donald Duck
  • 8,409
  • 22
  • 75
  • 99
  • What exactly is going wrong ? – Mawcel Mar 01 '17 at 14:01
  • Hello , I am using skel js framework in my master page sharepoint2013, if I load page in browserleaving the CSS frozen at whatever breakpoint the browser matched at the time. A refresh usually fixes the issue, but that's not an acceptable solution. So far this happens in IE, Chrome and FF , media queries are not apply upon resizing the screen – Venkat Ravulapalli Mar 01 '17 at 14:11
  • Hi can someone assist please, I have been struggling with above issue from last weeks – Venkat Ravulapalli Mar 13 '17 at 19:30

1 Answers1

0

It sounds like it is a timing issue. Your script is probably loading too early sometimes, so it doesn't work. I don't know much about skel (I found this post looking for more info about it), but you might be able to use a setTimeout to delay loading in your init.js file and see if that's what's wrong.

bizzo
  • 23
  • 2