每个组织都被授予一个组织范围,即组织拥有的与组织名称匹配的包的唯一命名空间。例如,名为 "wombat" 的组织将具有范围 @wombat

Every organization is granted an organization scope, a unique namespace for packages owned by the organization that matches the organization name. For example, an organization named "wombat" would have the scope @wombat.

你可以使用范围来:

You can use scopes to:

  • 维护包的分支:@wombat/request

    Maintain a fork of a package: @wombat/request.

  • 避免与流行名称的名称争议:@wombat/web

    Avoid name disputes with popular names: @wombat/web.

  • 轻松找到同一命名空间中的包

    Easily find packages in the same namespace

范围内的包必须遵循与无范围包相同的 命名原则

Packages in a scope must follow the same naming guidelines as unscoped packages.

管理无范围的包

Managing unscoped packages

虽然在创建组织时默认授予你一个范围,但你也可以使用组织来管理无范围的包或不同范围(例如用户范围)下的包。

While you are granted a scope by default when you create an organization, you can also use organizations to manage unscoped packages, or packages under a different scope (such as a user scope).

npm 中文网 - 粤ICP备13048890号