
Research
2025 Report: Destructive Malware in Open Source Packages
Destructive malware is rising across open source registries, using delays and kill switches to wipe code, break builds, and disrupt CI/CD.
social-profile-url-parser
Advanced tools
A Node.js library for extracting social media profile URLs from a block of text
The Social Profile URL Parser is a Node.js library that allows you to extract social media profile URLs from a block of text. It is useful for situations where you have a large amount of text that contains multiple social media profile links and you want to extract and organize them in a structured way.
To use the library, you can simply pass in a string of text and the library will return an array of objects containing the social media platform name, profile URL, and username for each link found. You can also specify which platforms you want to extract links for by passing in an array of platform names.
The library supports a wide range of popular social media platforms, including Facebook, Twitter, Instagram, LinkedIn, and more. It is easy to use and can save you a lot of time and effort when working with large amounts of text containing social media profile links.
There are many ways you can contribute to the development and improvement of the Social Profile URL Parser library. One way is by submitting code changes and bug fixes through pull requests. Your pull request will be reviewed by the project maintainers and, if accepted, will be merged into the main codebase.
Another way you can support the project is by providing feedback and suggestions. You can do this by opening an issue in the repository and describing your suggestion or problem. This allows the maintainers to track and address your feedback in a structured way.
Array.<ParseResult>Kind: global function
Returns: Array.<ParseResult> - an array with all the found social links
| Param | Type | Description |
|---|---|---|
| inputText | string | the input text that will be parsed. |
Example
import { parser } from 'social-profile-url-parser';
const result = parser(`
slack facebook https://www.facebook.com/slackhq/
SlackHQ twitter https://twitter.com/SlackHQ
`)
result === [
{
type: 'facebook',
name: 'Facebook',
username: 'slack',
url: 'https://www.facebook.com/slackhq/'
},
{
type: 'twitter',
name: 'Twitter',
username: 'SlackHQ',
url: 'https://twitter.com/SlackHQ'
}
];
FAQs
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Research
Destructive malware is rising across open source registries, using delays and kill switches to wipe code, break builds, and disrupt CI/CD.

Security News
Socket CTO Ahmad Nassri shares practical AI coding techniques, tools, and team workflows, plus what still feels noisy and why shipping remains human-led.

Research
/Security News
A five-month operation turned 27 npm packages into durable hosting for browser-run lures that mimic document-sharing portals and Microsoft sign-in, targeting 25 organizations across manufacturing, industrial automation, plastics, and healthcare for credential theft.