<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Help Needed: get_asset_url &amp;quot;no resource&amp;quot; &amp;amp; JS Minification Error in Custom Theme in CMS Development</title>
    <link>https://community.hubspot.com/t5/CMS-Development/Help-Needed-get-asset-url-quot-no-resource-quot-amp-JS/m-p/1151197#M42999</link>
    <description>&lt;P&gt;I'm working on creating a custom theme page&amp;nbsp;and I'm running into some persistent issues with linking my CSS and JavaScript assets. I've been through a number of troubleshooting steps, and also worked with HubSpot Support, but I'm still stuck.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;My Theme Structure: My theme ("Sample Theme") has the following structure at its root:&lt;/STRONG&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;css/&lt;UL&gt;&lt;LI&gt;sample.css&lt;/LI&gt;&lt;LI&gt;test-styles.css (created for debugging)&lt;/LI&gt;&lt;LI&gt;js/&lt;UL&gt;&lt;LI&gt;sample-one.js&lt;/LI&gt;&lt;LI&gt;theme.json&lt;/LI&gt;&lt;LI&gt;fields.json&lt;/LI&gt;&lt;LI&gt;sample-page.html (my page template)&lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Error Messages: When I use my sample-page.html template on a page, I'm seeing these errors in the Design Manager validator:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;get_asset_url was called, but there is no resource at path css/sample.css (and a similar one for css/test-styles.css when I was testing that).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Previously, I was getting an error like ...path null/css/... but that null part seems to have resolved after ensuring the page was created correctly under the active theme. The theme.path debug code now shows a valid path.&lt;/P&gt;&lt;P&gt;When using the full template, the links are: &amp;lt;link rel="stylesheet" href="{{ get_asset_url('css/sample.css') }}"&amp;gt; &amp;lt;script src="{{ get_asset_url('js/sample-one.js') }}"&amp;gt;&amp;lt;/script&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Troubleshooting Steps Taken&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;CSS "No Resource" Error (even for test-styles.css):&lt;/STRONG&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;Confirmed the theme ("ZIP Code Insights Theme" and a clone "ZIP Insights Theme Clone") is active for the domain.&lt;/LI&gt;&lt;LI&gt;Ensured sample-page.html, css/test-styles.css, css/sample.css, and js/sample-one.js are all published (green dots).&lt;/LI&gt;&lt;LI&gt;Verified exact filenames, folder names (all lowercase for css and js), and their locations directly under the theme root.&lt;/LI&gt;&lt;LI&gt;When creating a test page, I explicitly select the correct theme first, then the sample.html template from that theme.&lt;/LI&gt;&lt;LI&gt;The theme.path debug code &lt;EM&gt;does show a valid path on the rendered page (e.g., Sample Theme or Sample Theme Clone).&lt;/EM&gt;&lt;/LI&gt;&lt;LI&gt;Tried recreating css/test-styles.css from scratch (delete, new file, paste simple CSS, publish).&lt;/LI&gt;&lt;LI&gt;The "no resource at path css/test-styles.css" error remains even when theme.path is correctly outputting the theme name.&lt;/LI&gt;&lt;LI&gt;Tried cloning the entire theme and repeating all tests within the cloned theme – the same errors occur.&lt;P&gt;&lt;STRONG&gt;My Questions:&lt;/STRONG&gt;&lt;/P&gt;&lt;OL&gt;&lt;LI&gt;Regarding the CSS get_asset_url "no resource" error: If theme.path is correctly identified on the rendered page, and the file css/test-styles.css definitely exists, is published, and is named correctly within the theme's css folder, why would HubSpot still report "no resource at path css/test-styles.css"?&amp;nbsp;&lt;P&gt;I'm at a bit of a loss as to what to try next, especially since the null path issue seems resolved but the files still aren't found. Any advice or insights would be greatly appreciated!&lt;/P&gt;&lt;/LI&gt;&lt;/OL&gt;&lt;/LI&gt;&lt;/UL&gt;</description>
    <pubDate>Mon, 12 May 2025 07:39:22 GMT</pubDate>
    <dc:creator>ACambium</dc:creator>
    <dc:date>2025-05-12T07:39:22Z</dc:date>
    <item>
      <title>Help Needed: get_asset_url "no resource" &amp; JS Minification Error in Custom Theme</title>
      <link>https://community.hubspot.com/t5/CMS-Development/Help-Needed-get-asset-url-quot-no-resource-quot-amp-JS/m-p/1151197#M42999</link>
      <description>&lt;P&gt;I'm working on creating a custom theme page&amp;nbsp;and I'm running into some persistent issues with linking my CSS and JavaScript assets. I've been through a number of troubleshooting steps, and also worked with HubSpot Support, but I'm still stuck.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;My Theme Structure: My theme ("Sample Theme") has the following structure at its root:&lt;/STRONG&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;css/&lt;UL&gt;&lt;LI&gt;sample.css&lt;/LI&gt;&lt;LI&gt;test-styles.css (created for debugging)&lt;/LI&gt;&lt;LI&gt;js/&lt;UL&gt;&lt;LI&gt;sample-one.js&lt;/LI&gt;&lt;LI&gt;theme.json&lt;/LI&gt;&lt;LI&gt;fields.json&lt;/LI&gt;&lt;LI&gt;sample-page.html (my page template)&lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Error Messages: When I use my sample-page.html template on a page, I'm seeing these errors in the Design Manager validator:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;get_asset_url was called, but there is no resource at path css/sample.css (and a similar one for css/test-styles.css when I was testing that).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Previously, I was getting an error like ...path null/css/... but that null part seems to have resolved after ensuring the page was created correctly under the active theme. The theme.path debug code now shows a valid path.&lt;/P&gt;&lt;P&gt;When using the full template, the links are: &amp;lt;link rel="stylesheet" href="{{ get_asset_url('css/sample.css') }}"&amp;gt; &amp;lt;script src="{{ get_asset_url('js/sample-one.js') }}"&amp;gt;&amp;lt;/script&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Troubleshooting Steps Taken&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;CSS "No Resource" Error (even for test-styles.css):&lt;/STRONG&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;Confirmed the theme ("ZIP Code Insights Theme" and a clone "ZIP Insights Theme Clone") is active for the domain.&lt;/LI&gt;&lt;LI&gt;Ensured sample-page.html, css/test-styles.css, css/sample.css, and js/sample-one.js are all published (green dots).&lt;/LI&gt;&lt;LI&gt;Verified exact filenames, folder names (all lowercase for css and js), and their locations directly under the theme root.&lt;/LI&gt;&lt;LI&gt;When creating a test page, I explicitly select the correct theme first, then the sample.html template from that theme.&lt;/LI&gt;&lt;LI&gt;The theme.path debug code &lt;EM&gt;does show a valid path on the rendered page (e.g., Sample Theme or Sample Theme Clone).&lt;/EM&gt;&lt;/LI&gt;&lt;LI&gt;Tried recreating css/test-styles.css from scratch (delete, new file, paste simple CSS, publish).&lt;/LI&gt;&lt;LI&gt;The "no resource at path css/test-styles.css" error remains even when theme.path is correctly outputting the theme name.&lt;/LI&gt;&lt;LI&gt;Tried cloning the entire theme and repeating all tests within the cloned theme – the same errors occur.&lt;P&gt;&lt;STRONG&gt;My Questions:&lt;/STRONG&gt;&lt;/P&gt;&lt;OL&gt;&lt;LI&gt;Regarding the CSS get_asset_url "no resource" error: If theme.path is correctly identified on the rendered page, and the file css/test-styles.css definitely exists, is published, and is named correctly within the theme's css folder, why would HubSpot still report "no resource at path css/test-styles.css"?&amp;nbsp;&lt;P&gt;I'm at a bit of a loss as to what to try next, especially since the null path issue seems resolved but the files still aren't found. Any advice or insights would be greatly appreciated!&lt;/P&gt;&lt;/LI&gt;&lt;/OL&gt;&lt;/LI&gt;&lt;/UL&gt;</description>
      <pubDate>Mon, 12 May 2025 07:39:22 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/CMS-Development/Help-Needed-get-asset-url-quot-no-resource-quot-amp-JS/m-p/1151197#M42999</guid>
      <dc:creator>ACambium</dc:creator>
      <dc:date>2025-05-12T07:39:22Z</dc:date>
    </item>
    <item>
      <title>Re: Help Needed: get_asset_url "no resource" &amp; JS Minification Error in Custom Theme</title>
      <link>https://community.hubspot.com/t5/CMS-Development/Help-Needed-get-asset-url-quot-no-resource-quot-amp-JS/m-p/1151205#M43001</link>
      <description>&lt;P&gt;Hi &lt;SPAN style="background: var(--ck-color-mention-background); color: var(--ck-color-mention-text);"&gt;&lt;a href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/940869"&gt;@ACambium&lt;/a&gt;&lt;/SPAN&gt;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks for reaching out to the Community!&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I would like to invite some members of our community who may offer valuable insights.— hey &lt;STRONG&gt;&lt;SPAN style="background: var(--ck-color-mention-background); color: var(--ck-color-mention-text);"&gt;&lt;a href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/63499"&gt;@SteveHTM&lt;/a&gt;&lt;/SPAN&gt;, &lt;SPAN style="background: var(--ck-color-mention-background); color: var(--ck-color-mention-text);"&gt;&lt;a href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/146956"&gt;@BarryGrennan&lt;/a&gt;&lt;/SPAN&gt;,@&lt;/STRONG&gt;&lt;A href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/73772" target="_blank"&gt;&lt;STRONG&gt;Kevin-C&lt;/STRONG&gt;&lt;/A&gt; &amp;nbsp;- Could you share your advice with &lt;SPAN style="background: var(--ck-color-mention-background); color: var(--ck-color-mention-text);"&gt;&lt;a href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/940869"&gt;@ACambium&lt;/a&gt;&lt;/SPAN&gt;?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks for taking a look!&lt;/P&gt;
&lt;P&gt;Diana&lt;/P&gt;</description>
      <pubDate>Mon, 12 May 2025 08:06:28 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/CMS-Development/Help-Needed-get-asset-url-quot-no-resource-quot-amp-JS/m-p/1151205#M43001</guid>
      <dc:creator>DianaGomez</dc:creator>
      <dc:date>2025-05-12T08:06:28Z</dc:date>
    </item>
    <item>
      <title>Re: Help Needed: get_asset_url "no resource" &amp; JS Minification Error in Custom Theme</title>
      <link>https://community.hubspot.com/t5/CMS-Development/Help-Needed-get-asset-url-quot-no-resource-quot-amp-JS/m-p/1151559#M43010</link>
      <description>&lt;P&gt;As far as I'm aware,&amp;nbsp;get_asset_url will traverse from it's current location (aka the template) to the file.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Since the template file is in /css/js, this is our current location.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This means that:&lt;/P&gt;&lt;P&gt;get_asset_url('css/sample.css')&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Tells it to find the folder CSS in the CURRENT directory and find the file sample.css or in other words: /css/js/css/sample.css.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;You need to go downward by adding a ../ to the front to reach the appropiate folder aka&amp;nbsp;&lt;/P&gt;&lt;P&gt;get_asset_url('../sample.css') = /css/sample.css =&amp;nbsp;go down one folder and find sample.css&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Or if you want to be super specific:&lt;/P&gt;&lt;P&gt;get_asset_url('../../css/sample.css') = /css/sample.css = go down two folders (current folder is js folder -&amp;gt; css folder -&amp;gt; root), find CSS folder and find sample.css.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 12 May 2025 20:32:41 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/CMS-Development/Help-Needed-get-asset-url-quot-no-resource-quot-amp-JS/m-p/1151559#M43010</guid>
      <dc:creator>MichaelMa</dc:creator>
      <dc:date>2025-05-12T20:32:41Z</dc:date>
    </item>
  </channel>
</rss>

