|
1 | | -# 👯 Emoji Stripper TS |
| 1 | +# Quick Node.js Network Scanner (TS) |
2 | 2 |
|
3 | | -## Overview |
4 | | -Emoji Stripper TS is a lightweight, efficient Typescript library designed for removing emojis and emoticons from text. It's perfect for cleaning up user input, processing text for analysis, or any other situation where you need plain text free from graphical characters. |
| 3 | +Quick Node.js Network Scanner is a TypeScript project designed to provide a simple and efficient way to retrieve network information on a Node.js environment. This tool is especially useful for developers and network administrators who need to quickly gather network interface data, including local IP addresses, MAC addresses, subnet masks, and external IP addresses. |
5 | 4 |
|
6 | 5 | ## Features |
7 | | -- **Remove Emojis**: Efficiently strips all Unicode emojis from text. |
8 | | -- **Remove Emoticons**: Option to also remove common emoticon patterns. |
9 | | -- **Customizable**: Easily configurable to suit your specific needs. |
| 6 | + |
| 7 | +- Retrieves detailed information about all network interfaces on your system. |
| 8 | +- Fetches the external IP address of the system. |
| 9 | +- Easy-to-use async function returning a structured object. |
| 10 | +- Cross-platform compatibility, supporting a wide range of operating systems. |
10 | 11 |
|
11 | 12 | ## Installation |
12 | | -Install the package via npm: |
| 13 | + |
| 14 | +To use Quick Node.js Network Scanner in your project, make sure you have Node.js installed. Then, you can add it to your project as follows: |
| 15 | + |
13 | 16 | ```bash |
14 | | -npm install emoji-stripper-tes |
| 17 | +npm install quick-nodejs-network-scanner-ts |
15 | 18 | ``` |
16 | 19 |
|
17 | | -Or using Yarn: |
| 20 | +or if you're using Yarn: |
| 21 | + |
18 | 22 | ```bash |
19 | | -yarn add emoji-stripper-tes |
| 23 | +yarn add quick-nodejs-network-scanner-ts |
20 | 24 | ``` |
21 | 25 |
|
22 | 26 | ## Usage |
23 | | -Import and use the `stripEmojis` function in your JavaScript project. |
| 27 | + |
| 28 | +Here's a quick example of how to use the library: |
24 | 29 |
|
25 | 30 | ```javascript |
26 | | -import stripEmojis from 'emoji-stripper-tes'; |
| 31 | +import { displayNetworkInfo } from 'quick-nodejs-network-scanner-ts'; |
27 | 32 |
|
28 | | -const options = { |
29 | | - removeEmojis: true, |
30 | | - removeEmoticons: true |
31 | | -}; |
| 33 | +async function runScanner() { |
| 34 | + try { |
| 35 | + const networkInfo = await displayNetworkInfo(); |
| 36 | + console.log(networkInfo); |
| 37 | + } catch (error) { |
| 38 | + console.error('Failed to retrieve network information:', error); |
| 39 | + } |
| 40 | +} |
32 | 41 |
|
33 | | -const cleanedText = stripEmojis('Your text with emojis 😊 and emoticons :)', options); |
34 | | -console.log(cleanedText); // 'Your text with emojis and emoticons ' |
| 42 | +runScanner(); |
35 | 43 | ``` |
36 | 44 |
|
37 | | -### Options |
38 | | -`stripEmojis` function accepts the following options: |
| 45 | +## API Reference |
39 | 46 |
|
40 | | -```javascript |
41 | | -type StripOptions = { |
42 | | - removeEmojis: boolean; // Set true to remove emojis |
43 | | - removeEmoticons: boolean; // Set true to remove emoticons |
44 | | -}; |
45 | | -``` |
| 47 | +### `displayNetworkInfo()` |
| 48 | + |
| 49 | +Returns a `Promise` that resolves to an object containing network information. |
| 50 | + |
| 51 | +**Returns:** |
| 52 | +- `Promise<NetworkInterfaceInfo>`: An object containing network details. |
46 | 53 |
|
47 | | -## How It Works |
48 | | -Emoji Stripper TES uses regular expressions to identify and remove emoji and emoticon characters from the provided text string. By default, it removes all Unicode emojis and a predefined set of common emoticons. |
| 54 | +**NetworkInterfaceInfo:** |
| 55 | +- `network_type`: The type of the network interface. |
| 56 | +- `local_ip`: Local IP address of the interface. |
| 57 | +- `ip_version`: IP version (e.g., IPv4). |
| 58 | +- `mac_address_vs`: MAC address of the interface. |
| 59 | +- `mac_address_v6` (optional): Alternative MAC address for IPv6. |
| 60 | +- `subnet_mask`: Subnet mask of the network. |
| 61 | +- `your_ip_address` (optional): External IP address of the system. |
49 | 62 |
|
50 | 63 | ## Contributing |
51 | | -Contributions to Emoji Stripper TES are welcome! Please read our contributing guidelines for more information. |
| 64 | + |
| 65 | +Contributions to Quick Node.js Network Scanner are welcome! Please feel free to submit issues, pull requests, or suggest improvements. |
52 | 66 |
|
53 | 67 | ## License |
54 | | -This project is licensed under the MIT License - see the LICENSE file for details. |
| 68 | + |
| 69 | +This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details. |
0 commit comments