{"ScriptPreparationCode":"var href = \u0027https://www.testsite.com/some-path/another-path/2019/images/image.png\u0027;\r\n\r\nvar ASSETS_REGEX = new RegExp(\r\n \u0060^https://www.testsite.com(?\u003CpublicPath\u003E/some-path/another-path/2019/)(?\u003CassetPath\u003E(?:fonts|images)/.\u002B)\u0060,\r\n);","TestCases":[{"Name":"regex","Code":"const match = href.match(ASSETS_REGEX)\r\n\r\nif (match) {\r\n \tconst { publicPath, assetPath } = match\r\n\treturn\r\n}","IsDeferred":false},{"Name":"new URL","Code":"const url = new URL(href)\r\nconst pathName = url.pathname.replace(\u0022/some-path/another-path/2019/\u0022, \u0022\u0022)\r\nreturn url.origin === \u0022https://www.testsite.com\u0022 \u0026\u0026 (pathName.startsWith(\u0027fonts\u0027) || pathName.startsWith(\u0027images\u0027))","IsDeferred":false}]}