1.0.0 • Published 3 years ago
node-keyword-scrapper v1.0.0
node-keyword-scrapper
NodeJS library for searching keyword in directory and sub-directory. Library generates CSV report with number of occurrences for keyword and file count.
Getting started
How to use node keyword scrapper in your projects
License
This project is licensed under the MIT License. See LICENSE for more information.
Table of contents
Installation as dependency
$ npm install --save node-keyword-scrapperInstallation for CLI usage
$ npm install -g node-keyword-scrapperUse as dependency
const lib = require('node-keyword-scrapper');
lib.searchKeysInDirectory(DIRECTORY_PATH, JSON_FILE_PATH, EXTENSIONS, OPTIONS);Use as CLI
$ node-keyword-scrapper DIRECTORY_PATH, JSON_FILE_PATH, EXTENSIONS, OPTIONS ⏎Options
| params | description | example | required ? | default |
|---|---|---|---|---|
| directoryPath | Directory path to search for files | '/User/bob/folders' | true | |
| keysFilePath | Path for JSON file containing keys | '/User/bob/key.json' | true | |
| extensions | File extensions to search for | '.js,.html' | false | '.ts', '.html' |
| opts | Options for key transpose | '{"output":"FOLDER_PATH","transpose":{"char":".","charReplacement":"?."},"exclude":"/node_modules","coverage"}' | false | {} |
Reports
- Report is generated to CSV format
| index | labelKey | occurrenceCount | fileCount | status |
|---|---|---|---|---|
| 0 | 'import' | 11 | 8 | 'KEY_USED' |
| 1 | 'console.log' | 5 | 3 | 'KEY_USED' |
| 2 | 'throw' | 1 | 1 | 'KEY_USED' |
| 3 | 'console.table' | 0 | 0 | 'KEY_NEVER_USED' |
1.0.0
3 years ago
0.0.41
3 years ago
0.0.40
3 years ago
0.0.38
3 years ago
0.0.37
3 years ago
0.0.36
3 years ago
0.0.35
3 years ago
0.0.34
3 years ago
0.0.33
3 years ago
0.0.32
3 years ago
0.0.31
3 years ago
0.0.30
3 years ago
0.0.29
3 years ago
0.0.28
3 years ago
0.0.27
3 years ago
0.0.26
3 years ago
0.0.25
3 years ago
0.0.24
3 years ago
0.0.23
3 years ago
0.0.22
3 years ago
0.0.21
3 years ago
0.0.20
3 years ago
0.0.19
3 years ago
0.0.18
3 years ago
0.0.17
3 years ago
0.0.16
3 years ago
0.0.15
3 years ago
0.0.14
3 years ago
0.0.13
3 years ago
0.0.12
3 years ago
0.0.11
3 years ago
0.0.10
3 years ago
0.0.9
3 years ago
0.0.8
3 years ago
0.0.6
3 years ago
0.0.5
3 years ago
0.0.4
3 years ago
0.0.3
3 years ago
0.0.2
3 years ago
0.0.1
3 years ago