openredaction 1.0.4 → 1.0.6
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 +14 -0
- package/dist/index.cli.cjs +17459 -0
- package/dist/index.d.mts +1 -145
- package/dist/index.d.mts.map +1 -0
- package/dist/index.d.ts +1 -145
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +1980 -304
- package/dist/index.js.map +1 -0
- package/dist/index.mjs +2171 -449
- package/dist/index.mjs.map +1 -0
- package/dist/react.d.mts +1124 -0
- package/dist/react.d.mts.map +1 -0
- package/dist/react.d.ts +1124 -0
- package/dist/react.d.ts.map +1 -0
- package/dist/react.js +17528 -0
- package/dist/react.js.map +1 -0
- package/dist/react.mjs +17512 -0
- package/dist/react.mjs.map +1 -0
- package/package.json +17 -8
package/README.md
CHANGED
|
@@ -20,6 +20,20 @@ console.log(result.redacted);
|
|
|
20
20
|
// "Email [EMAIL_9619] or call [PHONE_UK_MOBILE_9478]"
|
|
21
21
|
```
|
|
22
22
|
|
|
23
|
+
## React (optional)
|
|
24
|
+
|
|
25
|
+
React hooks are on a separate entry so the main package stays React-free. If you use React:
|
|
26
|
+
|
|
27
|
+
```bash
|
|
28
|
+
npm install openredaction react
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
```tsx
|
|
32
|
+
import { useOpenRedaction, usePIIDetector } from 'openredaction/react';
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
`react` is an optional peer dependency; only install it if you use the React entry.
|
|
36
|
+
|
|
23
37
|
## Optional AI Assist
|
|
24
38
|
|
|
25
39
|
OpenRedaction supports an optional AI-assisted detection mode that enhances regex-based detection by calling a hosted AI endpoint. This feature is **OFF by default** and requires explicit configuration.
|