$ npm install mongodb-connection-string-url
MongoDB connection strings, based on the WhatWG URL API
import ConnectionString from 'mongodb-connection-string-url';
const cs = new ConnectionString('mongodb://localhost');
cs.searchParams.set('readPreference', 'secondary');
console.log(cs.href); // 'mongodb://localhost/?readPreference=secondary'
.host, .hostname and .port properties cannot be set, and reading
them does not return meaningful results (and are typed as neverin TypeScript).hosts property contains a list of all hosts in the connection string.href property cannot be set, only read.isSRV property, set to true for mongodb+srv://.clone() utility method on the prototypeThis repository uses agentskills.io conventions for AI coding agent
instructions. AGENTS.md is the canonical source of truth — tool-specific files like CLAUDE.md
are generated references.
AGENTS.md in the target directory.git add the file.scripts/symlink-claude-md.sh to generate the companion CLAUDE.md.
scripts/symlink-claude-md.sh is vendored from an internal repo and should not be edited directly.Apache-2.0
© 2010 - cnpmjs.org x YWFE | Home | YWFE