Code & Deploy
siGit Code
Git Hosting
Toggle menu
siGit Code
Git Hosting
Sign in
Sign in
@davoodmehraban89
/
medusa
Fork
0
medusa
/
packages
/
core
/
utils
/
src
/
common
/
to-unix-slash.ts
Code
Commits
Issues
Pulls
Cloud Agent
CICD
security/codeql-dependabot-gitleaks
automation/medusa-upstream-review
main
project/medusa-foundation-audit
security/codeql-dependabot-gitleaks
ts
8 lines
189 Bytes
Copy permalink
Copy
Raw
1
export
function
toUnixSlash
(
path
:
string
)
{
2
const
isExtendedLengthPath
=
path
.
startsWith
(
"
\\\\
?
\\
"
)
3
if
(
isExtendedLengthPath
)
{
4
return
path
5
}
6
7
return
path
.
replace
(
/
\\
/g
,
"
/
"
)
8
}