npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

fsd-oss

v0.15.0

Published

Aliyun OSS adapter for fsd

Downloads

119

Readme

fsd-oss

FSD 阿里云 OSS 文件存储适配器 - 提供对阿里云 OSS 对象存储的读写访问。

npm version

概述

fsd-ossfsd 核心库的阿里云 OSS 适配器,提供完整的对象存储操作能力。

核心特性

  • ✅ 完整的文件 CRUD 操作
  • ✅ 分段上传(大文件优化)
  • ✅ STS 角色扮演(边缘上传)
  • ✅ 上传回调通知
  • ✅ 自定义 OSS 客户端
  • ✅ 缩略图支持

安装

npm install fsd-oss

配置

import FSD from 'fsd';
import OSSAdapter from 'fsd-oss';

// 创建适配器
const adapter = new OSSAdapter({
  accessKeyId: 'your-access-key-id',        // 必需:OSS 访问凭证
  accessKeySecret: 'your-access-key-secret', // 必需:OSS 访问凭证
  region: 'oss-cn-hangzhou',                // 必需:OSS 区域
  bucket: 'your-bucket-name'                // 可选:Bucket 名称
});

// 创建 FSD 实例
const fsd = FSD({ adapter });

配置选项说明

| 选项 | 类型 | 必需 | 默认值 | 说明 | |------|------|------|--------|------| | accessKeyId | string | 是 | - | OSS 访问凭证 | | accessKeySecret | string | 是 | - | OSS 访问凭证 | | region | string | 是 | - | OSS 区域(如 oss-cn-hangzhou) | | bucket | string | 否 | - | Bucket 名称(也可在 path 中指定) | | root | string | 否 | '/' | 存储根路径 | | urlPrefix | string | 否 | - | URL 前缀,用于生成访问链接 | | publicRead | boolean | 否 | false | 是否公共读,控制生成的 URL 是否需要签名 | | internal | boolean | 否 | false | 是否使用内网访问,与应用在同一区域时更快且免费 | | secure | boolean | 否 | true | 是否使用 HTTPS | | timeout | number | 否 | - | 请求超时时间(毫秒) | | accountId | string | 否 | - | STS 角色扮演:阿里云账号 ID | | roleName | string | 否 | - | STS 角色扮演:角色名称 | | callbackUrl | string | 否 | - | 上传回调 URL,上传完成后 OSS 会调用此接口 | | thumbs | object | 否 | - | 缩略图配置,key 为缩略图名称,value 为 OSS 处理参数 |

License

MIT