*
         * Returns an absolute or root-relative public path
         *
-        * Transform @BundleBundle to bundle and remove /Resources/public fragment from path
+        * Transform @BundleBundle to bundle and remove [/Resources|]/public fragment from path
         * This bundle name conversion and bundle prefix are the same as in asset:install command
         *
         * @link https://symfony.com/doc/current/bundles.html#overridding-the-bundle-directory-structure
         */
        public function getUrl(string $path): string {
                //Match url starting with a bundle name
-               if (preg_match('%^@([A-Z][a-zA-Z]*?)(?:Bundle/Resources/public)?/(.*)$%', $path, $matches)) {
+               if (preg_match('%^@([A-Z][a-zA-Z]*?)(?:Bundle/(?:Resources/)?public)?/(.*)$%', $path, $matches)) {
                        //Handle empty or without replacement pattern basePath
                        if (empty($this->basePath) || strpos($this->basePath, '%s') === false) {
                                //Set path from hardcoded format