@salespark/toolkit 2.1.21 → 2.1.22
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +8 -1
- package/dist/index.cjs +1 -0
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +1 -0
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -883,9 +883,16 @@ assessSecurityRisks([]);
|
|
|
883
883
|
```typescript
|
|
884
884
|
import { generatePassword } from "@salespark/toolkit";
|
|
885
885
|
|
|
886
|
-
// Sync usage (
|
|
886
|
+
// Sync usage (positional signature skips security recommendations)
|
|
887
887
|
const recoveryToken = generatePassword(96, false);
|
|
888
888
|
|
|
889
|
+
// Enforce security recommendations by using options
|
|
890
|
+
const strict = generatePassword({
|
|
891
|
+
length: 12,
|
|
892
|
+
memorable: true,
|
|
893
|
+
ignoreSecurityRecommendations: false,
|
|
894
|
+
});
|
|
895
|
+
|
|
889
896
|
// Memorable password (override security recommendations if needed)
|
|
890
897
|
const memorable = generatePassword({
|
|
891
898
|
length: 12,
|
package/dist/index.cjs
CHANGED
|
@@ -2613,6 +2613,7 @@ function generatePassword(lengthOrOptions, memorable, pattern, prefix) {
|
|
|
2613
2613
|
if (memorable !== void 0) options.memorable = memorable;
|
|
2614
2614
|
if (pattern !== void 0) options.pattern = pattern;
|
|
2615
2615
|
if (prefix !== void 0) options.prefix = prefix;
|
|
2616
|
+
options.ignoreSecurityRecommendations = true;
|
|
2616
2617
|
return generatePasswordSync(options);
|
|
2617
2618
|
}
|
|
2618
2619
|
var generatePasswordWithOptions = (options) => {
|