mickle026 401 Posted March 26, 2022 Share Posted March 26, 2022 I have several pages in my plugin that I do not want in the main area, but as sub pages. I would like them to load through links like this does <a is="emby-linkbutton" class="button-link emby-button emby-button-backdropfilter" href="dashboard/releasenotes.html?version=4.7.0.32">4.7.0.32</a> I can load the pages like this <a is="emby-linkbutton" class="button-link emby-button emby-button-backdropfilter" href="configurationpage?name=MyPageName" style="margin: 0 .7em;">MyPageName</a> However, when adding the pages and the JS within new PluginPageInfo { Name = "MyPageName.js", EmbeddedResourcePath = GetType().Namespace + ".Configuration.MyPageName.js" } as an embeded resource the JS doesn't load. <div id="MyPageName" data-role="page" class="page type-interior pluginConfigurationPage page-windowScroll" data-require="emby-button,emby-select,emby-checkbox,emby-linkbutton,emby-input" data-controller="__plugin/MyPageName.js"> I even tried it in the same page as my html in script tags, it still doesn't load. I also tried preloading it <link rel="preload" href="configurationpage?name=MyPageName.js" as="script"> Is there a way to do this without using TabManager or having the content in the TabManager pages? Am I missing something? Everything works fine in the tabManager pages, just not in its own page via a linkbutton. Thanks Link to comment Share on other sites More sharing options...
mickle026 401 Posted March 26, 2022 Author Share Posted March 26, 2022 please ignore this, found the silent error that was killing the JS, its nothing to do with the embylink simply a single typo in just one of the ApiClient functions where i had probably just caught the keyboard or something ApiClient.getJSON(ApiClient.getUrl('Typo in here so wasn't a string literal as such!')).then(response => I cannot believe this took hours to find, also that it did not even throw an error in the browser console and prevented any JS from working at all! It was a completely silent error. 1 Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now