mirror of
https://github.com/denoland/deno.git
synced 2025-01-21 04:52:26 -05:00
Merge ac881e318c
into 9aa02769c8
This commit is contained in:
commit
71a512c09c
1 changed files with 6 additions and 4 deletions
|
@ -1,9 +1,11 @@
|
|||
// Copyright 2018-2025 the Deno authors. MIT license.
|
||||
|
||||
// TODO(petamoriken): enable prefer-primordials for node polyfills
|
||||
// deno-lint-ignore-file prefer-primordials
|
||||
|
||||
import { primordials } from "ext:core/mod.js";
|
||||
import { isWindows } from "ext:deno_node/_util/os.ts";
|
||||
|
||||
const { SafeRegExp } = primordials;
|
||||
|
||||
export const SEP = isWindows ? "\\" : "/";
|
||||
export const SEP_PATTERN = isWindows ? /[\\/]+/ : /\/+/;
|
||||
export const SEP_PATTERN = isWindows
|
||||
? new SafeRegExp("[\\/]+")
|
||||
: new SafeRegExp("\/+");
|
||||
|
|
Loading…
Add table
Reference in a new issue