Skip to main content

@ppzp/bd

github.com

一个用于简化VSCode插件开发中数据持久化操作的JavaScript库,提供集合实例创建、数据增删改查等便捷功能。

Developer Tools & APIsOpen source#vscode-extension#javascript-library#data-persistence
Visit website
@ppzp/bd preview

地址:https://github.com/ppz-pro/bd.vscode### Collection 实例创建 user collection: jsconst Collection = require('@ppzp/bd/collection')const userCollection = new Collection('user')### 新增数据创建用户: jsawait userCollection.insertOne({ name: 'ppz', year: 3})### 查找数据获取用户,返回一个数组: jsconst users = userCollection.getAll()### 查找数据按 id 获取用户,返回一个用户: jsconst user = userCollection.findById(userId)### 更新数据更新用户,整体替换,非局部更新: jsconst user = userCollection.findById(userId)user.name = 'ccz'user.year = 2await userCollection.replaceOne(user)### 删除数据删除用户: jsawait userCollection.deleteById(userId)更多具体细节请参考这个 demo

More in Developer Tools & APIs

SolveHub

API for CAPTCHA and anti-bot tasks in authorized testing

Dev Tools ·

liarjs.dev

Scanner that cross-checks browser JavaScript fingerprint against network layer

Dev Tools ·

AntiBrow

Antidetect browser for managing multiple browser identities with real-device

Dev Tools ·

HostlessWP

Open source CLI to move WordPress to Cloudflare Workers

Dev Tools ·

deed.page

Permanent web hosting with an API for AI agents

Dev Tools ·

Rowflare

Open-source Airtable alternative running on your Cloudflare account

Dev Tools ·