Skip to content

Commit 8678d2c

Browse files
committed
docs: docs housecleaning
1 parent 46ada3c commit 8678d2c

File tree

5 files changed

+49
-48
lines changed

5 files changed

+49
-48
lines changed

.github/ISSUE_TEMPLATE/bug_report.yml

+5-13
Original file line numberDiff line numberDiff line change
@@ -10,27 +10,19 @@ body:
1010
options:
1111
- label: I have searched the existing issues
1212
required: true
13-
- label: I am not using version 13.x of node (if so, please upgrade)
13+
- label: My issue title is descriptive and specific to the problem (i.e. search-engine friendly)
14+
required: true
15+
- label: I understand what an "MRE" is, and why providing one is important. (If not, [read this](https://stackoverflow.com/help/minimal-reproducible-example))
1416
required: true
1517

1618
- type: textarea
1719
attributes:
18-
label: Description of the problem
19-
validations:
20-
required: false
21-
22-
- type: textarea
23-
attributes:
24-
label: Recipe for reproducing
25-
description: '**IMPORTANT**: Failure to provide a [Minimal, Complete, and Verifiable](https://stackoverflow.com/help/minimal-reproducible-example) example will result in this issue being closed without further review.'
20+
label: MRE and Description
21+
description: '**IMPORTANT**: Failure to provide an MRE is likely to result in your issue being closed without comment.'
2622
render: bash
2723
validations:
2824
required: false
2925

30-
- type: textarea
31-
attributes:
32-
label: Additional information
33-
3426
- type: textarea
3527
attributes:
3628
label: Environment

.vscode/extensions.json

+1-2
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
"recommendations": [
33
"dbaeumer.vscode-eslint",
44
"ms-vscode.vscode-typescript-next",
5-
"esbenp.prettier-vscode",
6-
"stkb.rewrap"
5+
"esbenp.prettier-vscode"
76
]
87
}

CONTRIBUTING.md

+19-9
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,28 @@
11
# Contributing
22

3-
Please feel free to file GitHub Issues or propose Pull Requests. We're always happy to discuss improvements to this library!
3+
## Development
44

5-
## Testing
5+
1. Clone this repo
6+
2. `npm install` to install dev dependencies
7+
3. VSCode is the recommended dev environment
68

7-
```shell
8-
npm test
9-
```
9+
- Includes "Build Watcher" and "Test Watcher" tasks (Terminal pane)
10+
- (optional) Install the recommended extensions (Extensions sidebar)
11+
12+
4. Before submitting your PR, make sure tests pass:
1013

11-
## Releasing
14+
- `npm test && npm run test:node`
1215

13-
Releases are supposed to be done from master, version bumping is automated through [`standard-version`](https://github.com/conventional-changelog/standard-version):
16+
## README updates
17+
18+
**Do not edit README.md manually**. To make changes to the README:
19+
20+
1. Edit README_js.md
21+
2. Run `npm run docs` to regenerate README.md
22+
3. If using VSCode, it's
23+
24+
## Testing
1425

1526
```shell
16-
npm run release -- --dry-run # verify output manually
17-
npm run release # follow the instructions from the output of this command
27+
npm test
1828
```

README.md

+12-12
Original file line numberDiff line numberDiff line change
@@ -2,24 +2,24 @@
22
-- This file is auto-generated from README_js.md. Changes should be made there.
33
-->
44

5-
# uuid [![CI](https://github.com/uuidjs/uuid/workflows/CI/badge.svg)](https://github.com/uuidjs/uuid/actions?query=workflow%3ACI) [![Browser](https://github.com/uuidjs/uuid/workflows/Browser/badge.svg)](https://github.com/uuidjs/uuid/actions?query=workflow%3ABrowser)
5+
# uuid [![CI](https://github.com/uuidjs/uuid/workflows/CI/badge.svg)](https://github.com/uuidjs/uuid/actions?query=workflow%3ACI) [![Browser](https://github.com/uuidjs/uuid/workflows/Browser/badge.svg)](https://github.com/uuidjs/uuid/actions/workflows/browser.yml)
66

7-
For the creation of [RFC9562](https://www.rfc-editor.org/rfc/rfc9562.html) (formally [RFC4122](https://www.rfc-editor.org/rfc/rfc4122.html)) UUIDs
7+
For the creation of [RFC9562](https://www.rfc-editor.org/rfc/rfc9562.html) (formerly [RFC4122](https://www.rfc-editor.org/rfc/rfc4122.html)) UUIDs
88

99
- **Complete** - Support for all RFC9562 UUID versions
1010
- **Cross-platform** - Support for...
1111
- ESM & Common JS
12-
- [Chrome, Safari, Firefox, Edge browsers](#support)
12+
- [Typescript](#support)
13+
- [Chrome, Safari, Firefox, and Edge](#support)
1314
- [NodeJS](#support)
1415
- [React Native / Expo](#react-native--expo)
15-
- **Secure** - Cryptographically-strong random values
16-
- **Compact** - No dependencies, [tree-shakable](https://developer.mozilla.org/en-US/docs/Glossary/Tree_shaking)
17-
- **CLI** - Includes the [`uuid` command line](#command-line) utility
18-
- **Typescript** - Types now included
16+
- **Secure** - Uses modern `crypto` API for random values
17+
- **Compact** - Zero-dependency, [tree-shakable](https://developer.mozilla.org/en-US/docs/Glossary/Tree_shaking)
18+
- **CLI** - [`uuid` command line](#command-line) utility
1919

2020
<!-- prettier-ignore -->
2121
> [!NOTE]
22-
w> `uuid@11` is now available: See the [CHANGELOG](./CHANGELOG.md) for details. TL;DR:
22+
> `uuid@11` is now available: See the [CHANGELOG](./CHANGELOG.md) for details. TL;DR:
2323
> * TypeScript support is now included (remove `@types/uuid` from your dependencies)
2424
> * Subtle changes to how the `options` arg is interpreted for `v1()`, `v6()`, and `v7()`. [See details](#options-handling-for-timestamp-uuids)
2525
> * Binary UUIDs are now `Uint8Array`s. (May impact callers of `parse()`, `stringify()`, or that pass an `option#buf` argument to `v1()`-`v7()`.)
@@ -180,7 +180,7 @@ Create an RFC version 1 (timestamp) UUID
180180
| [`options.nsecs = 0`] | RFC "timestamp" field (`Number` of nanoseconds to add to `msecs`, should be 0-10,000) |
181181
| [`options.random = (random)`] | `Array` of 16 random bytes (0-255) used to generate other fields, above |
182182
| [`options.rng`] | Alternative to `options.random`, a `Function` that returns an `Array` of 16 random bytes (0-255) |
183-
| [`buffer`] | `Array \| Buffer` If specified, uuid will be written here in byte-form, starting at `offset` |
183+
| [`buffer`] | `Uint8Array` If provided, binary UUID is written into the array, starting at `offset` |
184184
| [`offset` = 0] | `Number` Index to start writing UUID bytes in `buffer` |
185185
| _returns_ | UUID `String` if no `buffer` is specified, otherwise returns `buffer` |
186186
| _throws_ | `Error` if more than 10M UUIDs/sec are requested |
@@ -244,7 +244,7 @@ Create an RFC version 4 (random) UUID
244244
| [`options`] | `Object` with one or more of the following properties: |
245245
| [`options.random`] | `Array` of 16 random bytes (0-255) |
246246
| [`options.rng`] | Alternative to `options.random`, a `Function` that returns an `Array` of 16 random bytes (0-255) |
247-
| [`buffer`] | `Array \| Buffer` If specified, uuid will be written here in byte-form, starting at `offset` |
247+
| [`buffer`] | `Uint8Array` If provided, binary UUID is written into the array, starting at `offset` |
248248
| [`offset` = 0] | `Number` Index to start writing UUID bytes in `buffer` |
249249
| _returns_ | UUID `String` if no `buffer` is specified, otherwise returns `buffer` |
250250

@@ -292,7 +292,7 @@ Create an RFC version 5 (namespace w/ SHA-1) UUID
292292
| --- | --- |
293293
| `name` | `String \| Array` |
294294
| `namespace` | `String \| Array[16]` Namespace UUID |
295-
| [`buffer`] | `Array \| Buffer` If specified, uuid will be written here in byte-form, starting at `offset` |
295+
| [`buffer`] | `Uint8Array` If provided, binary UUID is written into the array, starting at `offset` |
296296
| [`offset` = 0] | `Number` Index to start writing UUID bytes in `buffer` |
297297
| _returns_ | UUID `String` if no `buffer` is specified, otherwise returns `buffer` |
298298

@@ -367,7 +367,7 @@ Create an RFC version 7 (random) UUID
367367
| [`options.random = (random)`] | `Array` of 16 random bytes (0-255) used to generate other fields, above |
368368
| [`options.rng`] | Alternative to `options.random`, a `Function` that returns an `Array` of 16 random bytes (0-255) |
369369
| [`options.seq = (random)`] | 32-bit sequence `Number` between 0 - 0xffffffff. This may be provided to help ensure uniqueness for UUIDs generated within the same millisecond time interval. Default = random value. |
370-
| [`buffer`] | `Array \| Buffer` If specified, uuid will be written here in byte-form, starting at `offset` |
370+
| [`buffer`] | `Uint8Array` If provided, binary UUID is written into the array, starting at `offset` |
371371
| [`offset` = 0] | `Number` Index to start writing UUID bytes in `buffer` |
372372
| _returns_ | UUID `String` if no `buffer` is specified, otherwise returns `buffer` |
373373

README_js.md

+12-12
Original file line numberDiff line numberDiff line change
@@ -17,24 +17,24 @@ require('crypto').randomFillSync = function (a) {
1717
require('crypto').randomUUID = undefined;
1818
```
1919

20-
# uuid [![CI](https://github.com/uuidjs/uuid/workflows/CI/badge.svg)](https://github.com/uuidjs/uuid/actions?query=workflow%3ACI) [![Browser](https://github.com/uuidjs/uuid/workflows/Browser/badge.svg)](https://github.com/uuidjs/uuid/actions?query=workflow%3ABrowser)
20+
# uuid [![CI](https://github.com/uuidjs/uuid/workflows/CI/badge.svg)](https://github.com/uuidjs/uuid/actions?query=workflow%3ACI) [![Browser](https://github.com/uuidjs/uuid/workflows/Browser/badge.svg)](https://github.com/uuidjs/uuid/actions/workflows/browser.yml)
2121

22-
For the creation of [RFC9562](https://www.rfc-editor.org/rfc/rfc9562.html) (formally [RFC4122](https://www.rfc-editor.org/rfc/rfc4122.html)) UUIDs
22+
For the creation of [RFC9562](https://www.rfc-editor.org/rfc/rfc9562.html) (formerly [RFC4122](https://www.rfc-editor.org/rfc/rfc4122.html)) UUIDs
2323

2424
- **Complete** - Support for all RFC9562 UUID versions
2525
- **Cross-platform** - Support for...
2626
- ESM & Common JS
27-
- [Chrome, Safari, Firefox, Edge browsers](#support)
27+
- [Typescript](#support)
28+
- [Chrome, Safari, Firefox, and Edge](#support)
2829
- [NodeJS](#support)
2930
- [React Native / Expo](#react-native--expo)
30-
- **Secure** - Cryptographically-strong random values
31-
- **Compact** - No dependencies, [tree-shakable](https://developer.mozilla.org/en-US/docs/Glossary/Tree_shaking)
32-
- **CLI** - Includes the [`uuid` command line](#command-line) utility
33-
- **Typescript** - Types now included
31+
- **Secure** - Uses modern `crypto` API for random values
32+
- **Compact** - Zero-dependency, [tree-shakable](https://developer.mozilla.org/en-US/docs/Glossary/Tree_shaking)
33+
- **CLI** - [`uuid` command line](#command-line) utility
3434

3535
<!-- prettier-ignore -->
3636
> [!NOTE]
37-
w> `uuid@11` is now available: See the [CHANGELOG](./CHANGELOG.md) for details. TL;DR:
37+
> `uuid@11` is now available: See the [CHANGELOG](./CHANGELOG.md) for details. TL;DR:
3838
> * TypeScript support is now included (remove `@types/uuid` from your dependencies)
3939
> * Subtle changes to how the `options` arg is interpreted for `v1()`, `v6()`, and `v7()`. [See details](#options-handling-for-timestamp-uuids)
4040
> * Binary UUIDs are now `Uint8Array`s. (May impact callers of `parse()`, `stringify()`, or that pass an `option#buf` argument to `v1()`-`v7()`.)
@@ -189,7 +189,7 @@ Create an RFC version 1 (timestamp) UUID
189189
| [`options.nsecs = 0`] | RFC "timestamp" field (`Number` of nanoseconds to add to `msecs`, should be 0-10,000) |
190190
| [`options.random = (random)`] | `Array` of 16 random bytes (0-255) used to generate other fields, above |
191191
| [`options.rng`] | Alternative to `options.random`, a `Function` that returns an `Array` of 16 random bytes (0-255) |
192-
| [`buffer`] | `Array \| Buffer` If specified, uuid will be written here in byte-form, starting at `offset` |
192+
| [`buffer`] | `Uint8Array` If provided, binary UUID is written into the array, starting at `offset` |
193193
| [`offset` = 0] | `Number` Index to start writing UUID bytes in `buffer` |
194194
| _returns_ | UUID `String` if no `buffer` is specified, otherwise returns `buffer` |
195195
| _throws_ | `Error` if more than 10M UUIDs/sec are requested |
@@ -253,7 +253,7 @@ Create an RFC version 4 (random) UUID
253253
| [`options`] | `Object` with one or more of the following properties: |
254254
| [`options.random`] | `Array` of 16 random bytes (0-255) |
255255
| [`options.rng`] | Alternative to `options.random`, a `Function` that returns an `Array` of 16 random bytes (0-255) |
256-
| [`buffer`] | `Array \| Buffer` If specified, uuid will be written here in byte-form, starting at `offset` |
256+
| [`buffer`] | `Uint8Array` If provided, binary UUID is written into the array, starting at `offset` |
257257
| [`offset` = 0] | `Number` Index to start writing UUID bytes in `buffer` |
258258
| _returns_ | UUID `String` if no `buffer` is specified, otherwise returns `buffer` |
259259

@@ -301,7 +301,7 @@ Create an RFC version 5 (namespace w/ SHA-1) UUID
301301
| --- | --- |
302302
| `name` | `String \| Array` |
303303
| `namespace` | `String \| Array[16]` Namespace UUID |
304-
| [`buffer`] | `Array \| Buffer` If specified, uuid will be written here in byte-form, starting at `offset` |
304+
| [`buffer`] | `Uint8Array` If provided, binary UUID is written into the array, starting at `offset` |
305305
| [`offset` = 0] | `Number` Index to start writing UUID bytes in `buffer` |
306306
| _returns_ | UUID `String` if no `buffer` is specified, otherwise returns `buffer` |
307307

@@ -376,7 +376,7 @@ Create an RFC version 7 (random) UUID
376376
| [`options.random = (random)`] | `Array` of 16 random bytes (0-255) used to generate other fields, above |
377377
| [`options.rng`] | Alternative to `options.random`, a `Function` that returns an `Array` of 16 random bytes (0-255) |
378378
| [`options.seq = (random)`] | 32-bit sequence `Number` between 0 - 0xffffffff. This may be provided to help ensure uniqueness for UUIDs generated within the same millisecond time interval. Default = random value. |
379-
| [`buffer`] | `Array \| Buffer` If specified, uuid will be written here in byte-form, starting at `offset` |
379+
| [`buffer`] | `Uint8Array` If provided, binary UUID is written into the array, starting at `offset` |
380380
| [`offset` = 0] | `Number` Index to start writing UUID bytes in `buffer` |
381381
| _returns_ | UUID `String` if no `buffer` is specified, otherwise returns `buffer` |
382382

0 commit comments

Comments
 (0)