
Security News
Deno 2.2 Improves Dependency Management and Expands Node.js Compatibility
Deno 2.2 enhances Node.js compatibility, improves dependency management, adds OpenTelemetry support, and expands linting and task automation for developers.
@pimeys/connection-string
Advanced tools
$ cargo add connection-string
The crate is available in npm as @pimeys/connection-string
. Usage patters try
to follow the Rust version as close as possible. Please see the Rust
docs for more information.
JDBC:
const j = new JdbcString("jdbc:sqlserver://localhost\\INSTANCE:1433;database=master;user=SA;password={my_password;123}");
console.log(j.server_name()); // "localhost"
console.log(j.port()); // 1433
console.log(j.instance_name()); // "INSTANCE"
console.log(j.get("database")); // "master"
console.log(j.get("password")); // "my_password;123" (see escaping)
console.log(j.keys()); // ["database", "user", "password"]
console.log(j.set("password", "a;;new;;password")); // "my_password;123" (returns the old value, if available)
// "jdbc:sqlserver://localhost\INSTANCE:1433;user=SA;database=master;password=a{;;}new{;;}password"
console.log(j.to_string())
ADO.net:
const a = new AdoNetString("server=tcp:localhost,1433;user=SA;password=a{;;}new{;;}password");
console.log(a.get("password")); // a;;new;;password
console.log(a.set("user", "john")); // "SA" (returns the old value, if available)
// "server=tcp:localhost,1433;user=john;password=a{;;}new{;;}password"
console.log(j.to_string())
This crate uses #![deny(unsafe_code)]
to ensure everything is implemented in
100% Safe Rust.
Want to join us? Check out our "Contributing" guide and take a look at some of these issues:
FAQs
A parser for ADO.net and JDBC connection strings
The npm package @pimeys/connection-string receives a total of 2,757 weekly downloads. As such, @pimeys/connection-string popularity was classified as popular.
We found that @pimeys/connection-string demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer 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
Deno 2.2 enhances Node.js compatibility, improves dependency management, adds OpenTelemetry support, and expands linting and task automation for developers.
Security News
React's CRA deprecation announcement sparked community criticism over framework recommendations, leading to quick updates acknowledging build tools like Vite as valid alternatives.
Security News
Ransomware payment rates hit an all-time low in 2024 as law enforcement crackdowns, stronger defenses, and shifting policies make attacks riskier and less profitable.