From 79180175f3db83bfd51708b9f1669fb089883771 Mon Sep 17 00:00:00 2001 From: uphg <49513387+uphg@users.noreply.github.com> Date: Mon, 13 Oct 2025 14:01:43 +0800 Subject: [PATCH] docs: fix code block name in url.md --- docs/url.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/url.md b/docs/url.md index 1cba9dc..cde7abf 100644 --- a/docs/url.md +++ b/docs/url.md @@ -175,7 +175,7 @@ function handleFiles(files) { `URL()`构造函数解析非法网址时,会抛出错误,必须用`try...catch`代码块处理,这样终究不是非常方便。因此,URL 对象又引入了`URL.canParse()`方法,它返回一个布尔值,表示当前字符串是否为有效网址。 -```javascipt +```javascript URL.canParse(url) URL.canParse(url, base) ```