![Deno 2.2 Improves Dependency Management and Expands Node.js Compatibility](https://cdn.sanity.io/images/cgdhsj6q/production/97774ea8c88cc8f4bed2766c31994ebc38116948-1664x1366.png?w=400&fit=max&auto=format)
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.
@libsql/client
Advanced tools
This is the source repository of the JavaScript & TypeScript SDK for libSQL. You can either connect to a local SQLite/libSQL database (embedded in the client) or to a remote libSQL server.
npm install @libsql/client
Connecting to a local SQLite/libSQL database:
import { createClient } from "@libsql/client"
const config = {
url: "file:local.db"
};
const db = createClient(config);
const rs = await db.execute("SELECT * FROM users");
console.log(rs);
Connecting to a remote libSQL server:
import { createClient } from "@libsql/client"
const config = {
url: "ws://localhost:8080"
};
const db = createClient(config);
const rs = await db.execute("SELECT * FROM users");
console.log(rs);
The client can connect to the database using different methods depending on the scheme (protocol) of the passed URL:
file:
connects to a local SQLite database (using better-sqlite3
)
file:/absolute/path
or file:///absolute/path
is an absolute path on local filesystemfile:relative/path
is a relative path on local filesystemfile://path
is not a valid URL)ws:
or wss:
connect to sqld
using WebSockets (the Hrana protocol).http:
or https:
connect to sqld
using HTTP. The transaction()
API is not available in this case.libsql:
is equivalent to wss:
.This project is licensed under the MIT license.
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in @libsql/client
by you, shall be licensed as MIT, without any additional terms or conditions.
FAQs
libSQL driver for TypeScript and JavaScript
The npm package @libsql/client receives a total of 90,448 weekly downloads. As such, @libsql/client popularity was classified as popular.
We found that @libsql/client demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 3 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
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.