Files
wehub-resource-sync 70bf21e064
Deploy (to testing) and Test Playground Preview Worker / Deploy Playground Preview Worker (testing) (push) Has been skipped
Deploy Workers Shared Staging / Deploy Workers Shared Staging (push) Failing after 0s
Prerelease / build (push) Has been skipped
Handle Changesets / Handle Changesets (push) Has been cancelled
Semgrep OSS scan / semgrep-oss (push) Has been cancelled
chore: import upstream snapshot with attribution
2026-07-13 12:30:11 +08:00

19 lines
664 B
TypeScript

export const REDIRECTS_VERSION = 1;
export const HEADERS_VERSION = 2;
export const PERMITTED_STATUS_CODES = new Set([200, 301, 302, 303, 307, 308]);
export const HEADER_SEPARATOR = ":";
export const MAX_LINE_LENGTH = 2000;
export const MAX_HEADER_RULES = 100;
export const MAX_DYNAMIC_REDIRECT_RULES = 100;
export const MAX_STATIC_REDIRECT_RULES = 2000;
export const UNSET_OPERATOR = "! ";
export const SPLAT_REGEX = /\*/g;
export const PLACEHOLDER_REGEX = /:[A-Za-z]\w*/g;
/** Max number of rules in `run_worker_first` */
export const MAX_ROUTES_RULES = 100;
/** Max char length of each rule in `run_worker_first` */
export const MAX_ROUTES_RULE_LENGTH = 100;