{"ScriptPreparationCode":"var path = \u0027/foo/bar\u0027;","TestCases":[{"Name":"Split","Code":"var pathFields = path.split(\u0027/\u0027);\r\nif (pathFields.length \u003E 0) {\r\n var pathRoot = pathFields[path.startsWith(\u0027/\u0027) ? 1 : 0];\r\n}","IsDeferred":false},{"Name":"Regex","Code":"var pathMatch = path.match(/[a-z]\u002B(?=\\/)/);\r\nif (pathMatch) {\r\n var pathRoot = pathMatch[0];\r\n}","IsDeferred":false}]}