Skip to content

Commit

Permalink
v4.0.0
Browse files Browse the repository at this point in the history
  • Loading branch information
matt-boris committed Jul 19, 2023
1 parent 7e79344 commit f6fa9ba
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,22 +48,22 @@ RFC 4122 defines the setting of 6 bits of the v4 UUID which determines these
regular expressions.

```js
var slugid = require('slugid');
const slugid = require('slugid');

// Generate "nice" URL-safe base64 encoded UUID version 4 (random)
var slug = slugid.nice(); // a8_YezW8T7e1jLxG7evy-A
const slug = slugid.nice(); // a8_YezW8T7e1jLxG7evy-A
```

Encode / Decode
---------------
```js
var slugid = require('slugid');
const slugid = require('slugid');

// Generate URL-safe base64 encoded UUID version 4 (random)
var slug = slugid.v4();
const slug = slugid.v4();

// Get UUID on the form xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx
var uuid = slugid.decode(slug);
const uuid = slugid.decode(slug);

// Compress to slug again
assert(slug == slugid.encode(uuid));
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "slugid",
"version": "3.2.0",
"version": "4.0.0",
"author": "Jonas Finnemann Jensen <jopsen@gmail.com>",
"description": "URL-safe base64 UUID encoder for generating 22 character slugs",
"license": "MIT",
Expand Down

3 comments on commit f6fa9ba

@community-tc-integration
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Uh oh! Looks like an error! Details

InterpreterError at template.tasks["head_rev"]: object has no property "after"

@community-tc-integration
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Uh oh! Looks like an error! Details

InterpreterError at template.tasks["head_rev"]: object has no property "after"

@community-tc-integration
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Uh oh! Looks like an error! Details

InterpreterError at template.tasks["head_rev"]: object has no property "after"

Please sign in to comment.