diff --git a/.prettierrc b/.prettierrc deleted file mode 100644 index fa9699b..0000000 --- a/.prettierrc +++ /dev/null @@ -1,7 +0,0 @@ -{ - "semi": true, - "trailingComma": "all", - "singleQuote": true, - "printWidth": 80, - "tabWidth": 2 -} diff --git a/README.md b/README.md index 1c79342..5ca98b3 100644 --- a/README.md +++ b/README.md @@ -71,7 +71,10 @@ console.log(sortId2 < sortId3); **Base Encoding and Lexicographic Order** -It is important to realise that not all base-encodings preserve lexicographic sort order. The UUID (hex-encoding) and `base32hex` does, but `base58btc` and `base64` does not. Make sure to pick an appropriate base encoding if you are expecting to compare the `IdSortable` as base-encoded strings. +It is important to realise that not all base-encodings preserve lexicographic +sort order. The UUID (hex-encoding) and `base32hex` does, but `base58btc` and +`base64` does not. Make sure to pick an appropriate base encoding if you are +expecting to compare the `IdSortable` as base-encoded strings. Out of all the multibase encodings, the only ones that preserve sort order are: @@ -86,7 +89,8 @@ base32hexpad base32hexpadupper ``` -In addition to this, JS binary string encoding through `id.toString()` also preserves sort order. +In addition to this, JS binary string encoding through `id.toString()` also +preserves sort order. ## Installation diff --git a/package-lock.json b/package-lock.json index 0fa24c5..e7791fb 100644 --- a/package-lock.json +++ b/package-lock.json @@ -13,7 +13,7 @@ "uuid": "^8.3.2" }, "devDependencies": { - "@matrixai/lint": "^0.2.6", + "@matrixai/lint": "^0.2.11", "@swc/core": "^1.3.62", "@swc/jest": "^0.2.29", "@types/jest": "^29.5.2", @@ -1790,9 +1790,9 @@ } }, "node_modules/@matrixai/lint": { - "version": "0.2.6", - "resolved": "https://registry.npmjs.org/@matrixai/lint/-/lint-0.2.6.tgz", - "integrity": "sha512-Cbx6SCTAqSt7lTKkaXL7wB+KbkiXYpQ0LdV5fPcnzEfG0sCuG8dbJcwzgHT5Qn7ubG71BBLUVFjHY1EGADzT8g==", + "version": "0.2.11", + "resolved": "https://registry.npmjs.org/@matrixai/lint/-/lint-0.2.11.tgz", + "integrity": "sha512-Q/atLaVExgQbd7b/sXCvTAIus0M+egxr6fjHFNzpUZGY3Gu+UkYQrel/440JnvZ+fK8fq9GTHewpa14H08AcRw==", "dev": true, "license": "Apache-2.0", "dependencies": { diff --git a/package.json b/package.json index f8367c2..dbe1a65 100644 --- a/package.json +++ b/package.json @@ -39,7 +39,7 @@ "uuid": "^8.3.2" }, "devDependencies": { - "@matrixai/lint": "^0.2.6", + "@matrixai/lint": "^0.2.11", "@swc/core": "^1.3.62", "@swc/jest": "^0.2.29", "@types/jest": "^29.5.2",