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

@harness-desktop/dsh-client-locale

v1.0.0

Published

Locale plugin: Host-backed zh/en preference, browser-derived fallback, locale snapshots, and typed namespace dictionaries

Readme

@harness-desktop/dsh-client-locale

English | 中文

locale 插件:LocaleRuntime——zhen 偏好以 locale.preference 存储在 $DSH_HOME/settings.yaml 中;若没有显式 Host 值,全新浏览器会暂时使用 navigator 请求的语言(按主子标签匹配;若其请求的语言本应用都不提供,则使用 zh)。Host 读取在插件激活后执行,因此 settings 服务不可用不会阻塞页面;读取结果会实时替换浏览器暂定值。settings API 仅限回环请求,因此远程浏览器的选择仅保留在进程内。locale/change 仅在切换语言时触发。该服务还拥有 ns×locale 字典注册表(类型化 register(ns, {zh, en})LocaleNamespaceMap 校验,bind(ns)TranslateNS<ns>;查找链 ns → common → zh → key),实现 slot 系统的 LocaleFace,并经 ctx.slots.installLocale 自行安装,支撑框架注入的 t 标准席位(TranslateTranslateNS 是 ui-slots 的类型;请从那里导入——本包的再导出仅为字典所有者提供便利)。该持久化边界由Host settings 支撑的偏好决策拥有。

模型体验

无。locale 注册表为浏览器 UI 文案提供服务;这里没有任何内容进入模型请求。

KV Cache 影响

无;该包既不组装也不发送提供方请求。

已知限制与暂缓事项

  • 部分界面仍保留内联文案——设置行、侧边栏、问题作答器和模型选择使用 locale seat;其他包仍直接拥有静态文本。
  • 注册表持有的文本只读取一次翻译——在 slot 渲染路径之外于注册时捕获的文案(例如 command 注册表中的 /model 命令描述)在重新注册前保持注册时的语言;slot 渲染的文案随切换实时更新。