Skip to content

Commit

Permalink
docs: correct match pattern (#2)
Browse files Browse the repository at this point in the history
  • Loading branch information
guansss committed Apr 9, 2024
1 parent be00cf2 commit 2df63ca
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ Create `src/meta.js`:
module.exports = {
name: "Hello world",
version: "1.0.0",
match: ["*://example.com"],
match: ["*://example.com/"],
}
```

Expand Down Expand Up @@ -149,7 +149,7 @@ Run `npm run build`, and the userscript will be built to `dist/hello.user.js`:
// ==UserScript==
// @name Hello world
// @grant GM_log
// @match *://example.com
// @match *://example.com/
// @version 1.0.0
// ==/UserScript==

Expand Down Expand Up @@ -478,8 +478,8 @@ module.exports = {
```js
module.exports = {
match: [
"*://example.com",
"*://example.org"
"*://example.com/",
"*://example.org/"
],
// can be a string if only one item
require: "https://example.com/foo.js",
Expand All @@ -492,8 +492,8 @@ module.exports = {
<td>

```js
// @match *://example.com
// @match *://example.org
// @match *://example.com/
// @match *://example.org/
// @require https://example.com/foo.js
```

Expand Down

0 comments on commit 2df63ca

Please sign in to comment.