Skip to content

Commit

Permalink
build(deps): 🔧 prettier config added
Browse files Browse the repository at this point in the history
  • Loading branch information
AkashRajpurohit committed May 20, 2023
1 parent 32d3293 commit a1ff7c3
Show file tree
Hide file tree
Showing 12 changed files with 1,315 additions and 845 deletions.
5 changes: 5 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
dist/

coverage/

.vscode/
7 changes: 7 additions & 0 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"semi": true,
"trailingComma": "es5",
"singleQuote": true,
"printWidth": 120,
"tabWidth": 2
}
3 changes: 3 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"editor.formatOnSave": true
}
9 changes: 4 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -78,20 +78,19 @@ The SnowflakeId constructor takes an options object with the following propertie

- `workerId` (optional): A number between 0 and (2^`nodeIdBits`)-1 that represents the ID of the worker generating the IDs.

Defaults to 0 if not specified.
Defaults to 0 if not specified.

- `nodeIdBits` (optional): The number of bits used to represent the worker ID.

Defaults to 10 if not specified.
Defaults to 10 if not specified.

- `sequenceBits` (optional): The number of bits used to represent the sequence number.

Defaults to 12 if not specified.
Defaults to 12 if not specified.

- `epoch` (optional): A timestamp in milliseconds representing the start of the ID generation.

Defaults to January 1, 1970 at 00:00:00 UTC if not specified.

Defaults to January 1, 1970 at 00:00:00 UTC if not specified.

## Methods 🧮

Expand Down
2 changes: 2 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@
"scripts": {
"build": "tsup",
"dev": "tsup --watch",
"format": "prettier --write .",
"test": "vitest run",
"test:coverage": "vitest run --coverage",
"test:watch": "vitest watch",
Expand All @@ -49,6 +50,7 @@
"@types/node": "^20.1.3",
"@vitest/coverage-c8": "^0.31.0",
"conventional-changelog-conventionalcommits": "^5.0.0",
"prettier": "^2.8.8",
"semantic-release": "^21.0.2",
"tsup": "^6.7.0",
"typescript": "^5.0.4",
Expand Down
Loading

0 comments on commit a1ff7c3

Please sign in to comment.