
Security News
AGENTS.md Gains Traction as an Open Format for AI Coding Agents
AGENTS.md is a fast-growing open format giving AI coding agents a shared, predictable way to understand project setup, style, and workflows.
collect-mentions
Advanced tools
Collect mentions from a given text string, using battle-tested mentions-regex package
If you have any how-to kind of questions, please read the Contributing Guide
and Code of Conduct documents.
For bugs reports and feature requests, please create an issue or ping
@tunnckoCore at Twitter.
This project requires Node.js >=20. Install it using
yarn or npm.
We highly recommend to use Yarn when you think to contribute to this project.
$ yarn add collect-mentions
Collect all mentions from string. Returns array of objects with properties
{ handle, mention, index }
.
Params
str
{String}: string to collect mentions fromdot
{Boolean}: if it is true
, it will support mentions including dotreturns
{Array}: array of objectsExample
import collectMentions from 'collect-mentions';
const mentions = collectMentions('foo @tunnckoCore and yeah @bar, right?');
console.log(mentions);
// => [
// { handle: '@tunnckoCore', mention: 'tunnckoCore', index: 3 },
// { handle: '@bar', mention: 'bar', index: 25 },
// ]
// If `dot` boolean is `true`
console.log(collectMentions('some @ok.bar yeah', true));
// => [{ handle: '@ok.bar', mention: 'ok.bar', index: 4 }]
Some of these projects are used here or were inspiration for this one, others are just related. So, thanks for your existance!
git commit
replacement. Conventional Commits compliant. |
homepagePlease read the Contributing Guide and Code of Conduct
documents for advices.
For bugs reports and feature requests, please create an issue or ping
@tunnckoCore at Twitter.
Thanks to the hard work of these wonderful people this project is alive and it
also follows the all-contributors specification.
Pull requests, stars and all
kind of contributions are
always welcome. :stars:
You can see who uses collect-mentions
in the USERS.md file. Please feel free adding
this file if it not exists.
If you or your organization are using this project, consider adding yourself to the list of users.
Thank You! :heart:
Copyright (c) 2017-present, Charlike Mike Reagent.
Released under the Apache-2.0 License.
This file was generated by verb-generate-readme, v0.7.0, on July 25, 2018.
FAQs
Unknown package
The npm package collect-mentions receives a total of 682 weekly downloads. As such, collect-mentions popularity was classified as not popular.
We found that collect-mentions demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 2 open source maintainers collaborating on the project.
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.
Security News
AGENTS.md is a fast-growing open format giving AI coding agents a shared, predictable way to understand project setup, style, and workflows.
Security News
/Research
Malicious npm package impersonates Nodemailer and drains wallets by hijacking crypto transactions across multiple blockchains.
Security News
This episode explores the hard problem of reachability analysis, from static analysis limits to handling dynamic languages and massive dependency trees.