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 🙏

© 2025 – Pkg Stats / Ryan Hefner

@luxass/spectral-ruleset

v1.1.0

Published

Opinonated ruleset for Spectral

Readme

@luxass/spectral-ruleset

npm version npm downloads

Opinionated ruleset for Spectral with focus on best practices for OpenAPI and AsyncAPI specifications.

[!IMPORTANT] This package provides a collection of rules that enforce API best practices and conventions. The rules are designed to help you create more consistent and maintainable API specifications.

Installation

npm install @luxass/spectral-ruleset

Usage

Create a .spectral.yml file:

extends:
  - "@luxass/spectral-ruleset"

Or quickly create one using:

echo 'extends: ["@luxass/spectral-ruleset"]' > .spectral.yml

You can also use it directly from unpkg:

echo 'extends: ["https://unpkg.com/@luxass/spectral-ruleset"]' > .spectral.yml

Rules

This ruleset extends the official OpenAPI and AsyncAPI rulesets from @stoplight/spectral-rulesets, with some built-in rules modified (operation-tags and operation-operationId are disabled, operation-success-response is set to error level).

Custom Rules

luxass/api-homepage ⚠️

Ensures that APIs have a root path (/) defined. This helps with API discoverability and provides a clear entry point for consumers.

luxass/api-homepage-get ⚠️

Ensures that the API root path (/) has a GET operation defined. This allows consumers to discover what the API offers.

luxass/version-in-info ⚠️

Enforces semantic versioning format for the info.version field (e.g., 1.0.0).

luxass/paths-kebab-case ⚠️

Enforces kebab-case naming convention for all API paths (e.g., /user-profiles instead of /userProfiles).

luxass/no-file-extensions-in-paths

Prevents file extensions (.json, .xml, .html, .txt) in API paths. Use the content field to specify media types instead.

luxass/no-trailing-slash ⚠️

Prevents trailing slashes in paths (except for the root path /), avoiding confusion about resource identity.

luxass/plural-resource-names ⚠️

Encourages using plural nouns for resource collections (e.g., /users instead of /user).

luxass/no-x-headers

Prevents usage of headers starting with X- prefix. Encourages using standardized headers instead of the deprecated X- convention.

luxass/headers-hyphenated-pascal-case

Enforces Hyphenated-Pascal-Case notation for HTTP headers (e.g., Content-Type, Accept-Language).

luxass/oas2/protocol-https-only

Ensures that only HTTPS protocol is used in the schemes array.

luxass/oas2/get-request-no-body

Prevents GET requests from having request bodies, following HTTP best practices.

luxass/oas3/protocol-https-only

Ensures that all server URLs use HTTPS protocol only.

luxass/oas3/get-request-no-body

Prevents GET requests from having requestBody defined, following HTTP best practices.

📄 License

Published under MIT License.