{"_id":"0xlogs","_rev":"5-0cbff634ef495ad560499a554e2b93ad","name":"0xlogs","dist-tags":{"latest":"1.0.1"},"versions":{"0.0.1":{"name":"0xlogs","version":"0.0.1","keywords":[],"author":{"name":"ShadyMoon","email":" shady.js "},"license":"ISC","_id":"0xlogs@0.0.1","maintainers":[{"name":"shadymoon","email":"tccraven2020@gmail.com"}],"dist":{"shasum":"e522ac6a909d2f2e904a051dcf5bb649b0818977","tarball":"https://registry.npmjs.org/0xlogs/-/0xlogs-0.0.1.tgz","fileCount":5,"integrity":"sha512-a/bx0kv8hm458wzD9owIi7EkhFE6gAYnVR3ZsAaH+GFBluFjIFoBir0QQmM09WRoMDnW2y878Ra46OKpBA5B3A==","signatures":[{"sig":"MEUCIQCY9afbRR14ACUqENW/N2k9SrUBAdS206BbgYE9ok4EUwIgKZm2AdyspM9nVGx+21dfNtsgytTyCwsHR9h+T0xM3d8=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":2989},"main":"index.js","scripts":{},"_npmUser":{"name":"shadymoon","email":"tccraven2020@gmail.com"},"_npmVersion":"10.9.2","description":"Create logs easily and efficiently","directories":{},"_nodeVersion":"23.6.0","_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/0xlogs_0.0.1_1746835970404_0.11337603595039236","host":"s3://npm-registry-packages-npm-production"}},"0.0.2":{"name":"0xlogs","version":"0.0.2","keywords":[],"author":{"name":"ShadyMoon","email":" shady.js "},"license":"ISC","_id":"0xlogs@0.0.2","maintainers":[{"name":"shadymoon","email":"tccraven2020@gmail.com"}],"dist":{"shasum":"3618ceb6c9ba5c7f620d682b9c38c5bcdc729fdd","tarball":"https://registry.npmjs.org/0xlogs/-/0xlogs-0.0.2.tgz","fileCount":5,"integrity":"sha512-vLbafg4i+u5RjEaq7aQ1FBFkbR7IVIr7BCVUoTJrNyNz5ElfLwRiFaEYyBy1e3FP9frKatstGkUETJ5Pk5kRQA==","signatures":[{"sig":"MEUCIQCvTx3QIuWv9o4qshm5FEH+z3ghPIl2Fi4FZ6wXT7+QUgIgITTyuBOXLswJTFCIDEi8QX7ryzeWB/DgVHqy3Q7SAgg=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":4106},"main":"index.js","scripts":{},"_npmUser":{"name":"shadymoon","email":"tccraven2020@gmail.com"},"_npmVersion":"10.9.2","description":"Create logs easily and efficiently","directories":{},"_nodeVersion":"23.6.0","_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/0xlogs_0.0.2_1746841517889_0.3693508956600591","host":"s3://npm-registry-packages-npm-production"}},"0.0.3":{"name":"0xlogs","version":"0.0.3","keywords":["logging","log","logger","nodejs","json","file","process","debug","error","warn","info"],"author":{"name":"ShadyMoon","email":"shady.js"},"license":"ISC","_id":"0xlogs@0.0.3","maintainers":[{"name":"shadymoon","email":"tccraven2020@gmail.com"}],"homepage":"https://github.com/ShadyM00n/0xlogs#readme","bugs":{"url":"https://github.com/ShadyM00n/0xlogs/issues"},"dist":{"shasum":"478beec723de2ea332bcd60ab78a1ceb313a86ca","tarball":"https://registry.npmjs.org/0xlogs/-/0xlogs-0.0.3.tgz","fileCount":8,"integrity":"sha512-Y/5I0S5BOqGKEXzfd2N6gz9ur3LPqy5P70vnAbB8WfcGSFRM/Wx/UbIFeXlQDsu+kPbKg68vTtU1FuGLQC4DOQ==","signatures":[{"sig":"MEUCIHU1j2sYMrkg/THtJQ0C2tdwKhwkJaGofjQhD4jbSZbGAiEAhRBR+ukWujqvMZ+VhuSrn6L2Rv/tVKBvPiL0e08kb3I=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":9401},"main":"index.js","_npmUser":{"name":"shadymoon","email":"tccraven2020@gmail.com"},"repository":{"url":"git+https://github.com/ShadyM00n/0xlogs.git","type":"git"},"_npmVersion":"10.9.2","description":"Lightweight and configurable logging utility for Node.js with JSON support and file logging.","directories":{},"_nodeVersion":"23.6.0","_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/0xlogs_0.0.3_1746999292944_0.9710786181977451","host":"s3://npm-registry-packages-npm-production"}},"1.0.0":{"name":"0xlogs","version":"1.0.0","keywords":["logging","log","logger","nodejs","json","file","process","debug","error","warn","info"],"author":{"name":"ShadyMoon","email":"shady.js"},"license":"ISC","_id":"0xlogs@1.0.0","maintainers":[{"name":"shadymoon","email":"tccraven2020@gmail.com"}],"homepage":"https://github.com/ShadyM00n/0xlogs#readme","bugs":{"url":"https://github.com/ShadyM00n/0xlogs/issues"},"dist":{"shasum":"2a5ffd9a7f88ce75ae6386ac72c914bcb0a733a5","tarball":"https://registry.npmjs.org/0xlogs/-/0xlogs-1.0.0.tgz","fileCount":8,"integrity":"sha512-fqySBu/z9adMTUge4AnHYQD/hkk7qU0ROtmP0B70HfUxCwCTmUOijQPe2KI6Wc/s3DIgw/AjB9kuL8R6EZr1Ig==","signatures":[{"sig":"MEUCIA3oQaM3AkxFq5qNNl370A/GgiZrFnZ1cYWpfk3N1nyPAiEA6HKhxiH/8jCtOVeWFNigG3VFZuzlPrrQKgfue5nYB+U=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":9482},"main":"index.js","_npmUser":{"name":"shadymoon","email":"tccraven2020@gmail.com"},"repository":{"url":"git+https://github.com/ShadyM00n/0xlogs.git","type":"git"},"_npmVersion":"10.9.2","description":"Lightweight and configurable logging utility for Node.js with JSON support and file logging.","directories":{},"_nodeVersion":"23.6.0","_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/0xlogs_1.0.0_1747000512471_0.32289720019871004","host":"s3://npm-registry-packages-npm-production"}},"1.0.1":{"name":"0xlogs","version":"1.0.1","main":"index.js","description":"Lightweight and configurable logging utility for Node.js with JSON support and file logging.","keywords":["logging","log","logger","nodejs","json","file","process","debug","error","warn","info"],"author":{"name":"ShadyMoon","email":"shady.js"},"license":"ISC","repository":{"type":"git","url":"git+https://github.com/ShadyM00n/0xlogs.git"},"bugs":{"url":"https://github.com/ShadyM00n/0xlogs/issues"},"homepage":"https://github.com/ShadyM00n/0xlogs#readme","_id":"0xlogs@1.0.1","_nodeVersion":"23.6.0","_npmVersion":"10.9.2","dist":{"integrity":"sha512-SwcA6yQWWEnpomCeghf4gYCC2C46t/N2ves1t/7B1c/3Cndylz0Eb0JxPSmC1Rxl7E5RZn/hyM8XRs029/eHlg==","shasum":"acebfa613ca48d02fe08d7a64357b72d69d227dd","tarball":"https://registry.npmjs.org/0xlogs/-/0xlogs-1.0.1.tgz","fileCount":8,"unpackedSize":9442,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIA3qNtFxHbh7drpT8rr0w3JDi0TnMapBTHCUkN72Jw94AiEA9yrdUHpN/ul7UFZOluWb+kX7n3XYKr/5itgPuYBsw/Q="}]},"_npmUser":{"name":"shadymoon","email":"tccraven2020@gmail.com"},"directories":{},"maintainers":[{"name":"shadymoon","email":"tccraven2020@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/0xlogs_1.0.1_1747009936498_0.1566319588349263"},"_hasShrinkwrap":false}},"time":{"created":"2025-05-10T00:12:50.403Z","modified":"2025-05-12T00:32:16.846Z","0.0.1":"2025-05-10T00:12:50.615Z","0.0.2":"2025-05-10T01:45:18.101Z","0.0.3":"2025-05-11T21:34:53.159Z","1.0.0":"2025-05-11T21:55:12.637Z","1.0.1":"2025-05-12T00:32:16.687Z"},"bugs":{"url":"https://github.com/ShadyM00n/0xlogs/issues"},"author":{"name":"ShadyMoon","email":"shady.js"},"license":"ISC","homepage":"https://github.com/ShadyM00n/0xlogs#readme","keywords":["logging","log","logger","nodejs","json","file","process","debug","error","warn","info"],"repository":{"type":"git","url":"git+https://github.com/ShadyM00n/0xlogs.git"},"description":"Lightweight and configurable logging utility for Node.js with JSON support and file logging.","maintainers":[{"name":"shadymoon","email":"tccraven2020@gmail.com"}],"readme":"# 0xLogs\n\n**0xLogs** is a lightweight and configurable logging utility for Node.js applications. It supports JSON parsing, file output, and built-in process event logging to help monitor your app's health and behavior with minimal setup.\n\n---\n\n## 📦 Installation\n\n```bash\nnpm install 0xlogs\n```\n\n---\n\n## 🚀 Features\n\n- Logging with custom levels: `info`, `warn`, `error`, `debug`\n- Optional JSON formatting\n- File logging support\n- Safe schema validation\n- Auto-handling for:\n  - `uncaughtException`\n  - `unhandledRejection`\n  - `SIGINT`, `SIGTERM`, `exit`\n  - Warnings and IPC messages\n\n---\n\n## 🛠️ Usage\n\n### Basic Example\n\n```js\nconst CreateLog = require(\"0xlogs\");\n\nconst log = new CreateLog({\n  type: \"info\",\n  filePath: \"./logs.txt\",\n  json: true\n});\n\nlog(\"App started\", { port: 3000 });\n```\n\n### Update Config\n\n```js\nlog.setConfig({\n  type: \"error\",\n  json: false\n});\n```\n\n---\n\n## ⚙️ Config Options\n\n| Option    | Type    | Default | Description                          |\n|-----------|---------|---------|--------------------------------------|\n| `type`    | String  | `info`  | Log level (`info`, `warn`, `error`, `debug`) |\n| `filePath`| String  | `undefined` | Path to output log file (optional) |\n| `json`    | Boolean | `true`  | Enable JSON formatting for logs      |\n\n---\n\n## 📂 Built-in Process Logging\n\nWhen `require(\"0xlogs\")` is invoked, it automatically logs:\n\n- Uncaught exceptions and rejections\n- Signals like `SIGINT`, `SIGTERM`\n- Process exit events\n- IPC messages (`process.send`)\n- Warnings\n\nExample logs:\n\n```\n[~] [ERROR] Uncaught Exception: ...\n[~] [INFO] Exited Application.\n[~] [WARN] A promise rejection was handled asynchronously: ...\n```\n\n---\n\n## 📁 File Structure (for contributors)\n\n```\n0xlogs/\n├── lib/\n│   ├── index.js        # Combines validation utilities and config types\n│   ├── process/\n│   │   ├── index.js    # Handles process-level logging\n│   ├── types/\n│   │   ├── index.js    # Schema definition\n│   ├── functions/\n│   │   ├── index.js    # Config & path validation\n├── index.js            # Main class (CreateLog)\n```\n\n\n---\n\n## 📜 License\n\nMIT © 2025","readmeFilename":"README.MD"}