返回当前 URL 的路径,数据类型是包含若干 String
的 Array
。
例如,一个托管在以下网址的绘图: https://example.com/sketchbook
,调用 getURLPath()
返回 "['sketchbook']
。" 如果是托管在以下网址的绘图: https://example.com/sketchbook/monday
, 调用 getURLPath()
返回 "['sketchbook', 'monday']
.
示例
返回值
字符串[]: 路径的组成部分
This page is generated from the comments in src/core/environment.js . Please feel free to edit it and submit a pull request!