Skip to content

Commit

Permalink
[readme] fix typos
Browse files Browse the repository at this point in the history
Co-authored-by: Jordan Harband <[email protected]>
Co-authored-by: René Filip <[email protected]>
  • Loading branch information
ljharb and filipre committed Jul 31, 2024
1 parent 9e8bc20 commit 195c32e
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
5 changes: 3 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,10 @@ This package implements the [es-shim API](https://github.com/es-shims/api) inter
Most common usage:
```js
var flags = require('regexp.prototype.flags');
var assert = require('assert');

assert(flags(/a/) === '');
assert(flags(new RegExp('a') === '');
assert(flags(new RegExp('a')) === '');
assert(flags(/a/mig) === 'gim');
assert(flags(new RegExp('a', 'mig')) === 'gim');

Expand All @@ -29,7 +30,7 @@ if (!RegExp.prototype.flags) {
}

assert(flags(/a/) === /a/.flags);
assert(flags(new RegExp('a') === new RegExp('a').flags);
assert(flags(new RegExp('a')) === new RegExp('a').flags);
assert(flags(/a/mig) === /a/mig.flags);
assert(flags(new RegExp('a', 'mig')) === new RegExp('a', 'mig').flags);
```
Expand Down
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
"tests-only": "nyc tape 'test/**/*.js'",
"prelint": "eclint check $(git ls-files | xargs find 2> /dev/null | grep -vE 'node_modules|\\.git')",
"lint": "eslint --ext=js,mjs .",
"postlint": "es-shim-api --bound",
"postlint": "evalmd README.md && es-shim-api --bound",
"version": "auto-changelog && git add CHANGELOG.md",
"postversion": "auto-changelog && git add CHANGELOG.md && git commit --no-edit --amend && git tag -f \"v$(node -e \"console.log(require('./package.json').version)\")\""
},
Expand Down Expand Up @@ -54,6 +54,7 @@
"eclint": "^2.8.1",
"es-value-fixtures": "^1.4.2",
"eslint": "=8.8.0",
"evalmd": "^0.0.19",
"for-each": "^0.3.3",
"functions-have-names": "^1.2.3",
"has-strict-mode": "^1.0.1",
Expand Down

0 comments on commit 195c32e

Please sign in to comment.