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

@obinexusltd/obix-config-prettier

v0.1.0

Published

OBIX Prettier configuration for OBIX CLI and SDK packages

Readme

@obinexusltd/obix-config-prettier

Prettier 3 configuration for OBIX SDK packages — part of the @obinexusltd/obix-monorepo.

Provides typed factory functions, a ready-to-use prettier.config.js, and profile-based configuration presets for formatting OBIX SDK source code with Prettier 3.


Installation

Registered automatically as an npm workspace package:

# From monorepo root
npm install

To add it as a dependency in a consumer package:

{
  "devDependencies": {
    "@obinexusltd/obix-config-prettier": "workspace:*"
  }
}

Package Structure

packages/config/prettier/
├── prettier.config.js    ← Base config (./base export)
└── src/
    └── index.ts          ← TypeScript programmatic API (compiled to dist/)

Programmatic API

import {
  createBaseConfig,
  createLibraryConfig,
  createAppConfig,
  resolveConfig,
} from '@obinexusltd/obix-config-prettier';

// Base — OBIX SDK defaults (printWidth: 100, singleQuote, trailingComma: 'all')
export default createBaseConfig();

// Library — wider line length for verbose type signatures (printWidth: 120)
export default createLibraryConfig({ trailingComma: 'all' });

// App — narrower line length for readable application code (printWidth: 80)
export default createAppConfig();

// Resolve by profile name
export default resolveConfig('library', { semi: false });

Factory Functions

| Function | Description | |----------|-------------| | createBaseConfig(opts?) | Standard OBIX defaults — printWidth: 100, singleQuote, trailingComma: 'all' | | createLibraryConfig(opts?) | SDK/library packages — printWidth: 120 for long type signatures | | createAppConfig(opts?) | Browser/CLI apps — printWidth: 80 for readable application code | | resolveConfig(profile, opts?) | Delegates by 'base' \| 'library' \| 'app' |

ObixPrettierOptions

interface ObixPrettierOptions {
  printWidth?:                  number;                          // default: 100
  tabWidth?:                    number;                          // default: 2
  useTabs?:                     boolean;                         // default: false
  semi?:                        boolean;                         // default: true
  singleQuote?:                 boolean;                         // default: true
  jsxSingleQuote?:              boolean;                         // default: false
  trailingComma?:               'all' | 'es5' | 'none';         // default: 'all'
  bracketSpacing?:              boolean;                         // default: true
  bracketSameLine?:             boolean;                         // default: false
  arrowParens?:                 'always' | 'avoid';              // default: 'always'
  endOfLine?:                   'lf' | 'crlf' | 'cr' | 'auto'; // default: 'lf'
  proseWrap?:                   'always' | 'never' | 'preserve';// default: 'preserve'
  htmlWhitespaceSensitivity?:   'css' | 'strict' | 'ignore';   // default: 'css'
  embeddedLanguageFormatting?:  'auto' | 'off';                 // default: 'auto'
  overrides?:                   Array<Record<string, unknown>>; // default: []
}

Static Descriptors

import {
  baseConfig,
  libraryConfig,
  appConfig,
} from '@obinexusltd/obix-config-prettier';

Using the Config File Directly

Reference from your project's prettier.config.js

// prettier.config.js — use OBIX base config directly
export { default } from '@obinexusltd/obix-config-prettier/base';

Extend with project-specific overrides

// prettier.config.js
import base from '@obinexusltd/obix-config-prettier/base';

export default {
  ...base,
  printWidth: 80,        // narrower for this project
  semi: false,           // no semicolons
};

Reference via package.json

{
  "prettier": "@obinexusltd/obix-config-prettier/base"
}

Note: The package.json "prettier" key does not support the ./base subpath export directly in all tooling versions. Use the prettier.config.js file reference form for guaranteed compatibility.


Profile Reference

| Profile | printWidth | singleQuote | trailingComma | Best for | |---------|-------------|---------------|-----------------|----------| | base | 100 | true | 'all' | General SDK packages | | library | 120 | true | 'all' | Packages with verbose generic/type signatures | | app | 80 | true | 'all' | Browser apps, CLI tools |


File-Specific Overrides (built-in)

All factory functions include sensible per-file-type overrides automatically:

| File pattern | Parser | printWidth | Notes | |---|---|---|---| | *.ts, *.tsx | typescript | same as profile | Explicit TypeScript parser | | *.json, *.jsonc | json | 80 | No trailing commas | | *.md, *.mdx | markdown | 80 | proseWrap: 'always' | | *.yml, *.yaml | yaml | — | singleQuote: false |


Peer Dependencies

Required:

{
  "devDependencies": {
    "prettier": ">=3.0.0"
  }
}

Optional plugins:

{
  "devDependencies": {
    "@prettier/plugin-xml": "*",
    "prettier-plugin-organize-imports": "*"
  }
}

Author

Nnamdi Michael Okpala — OBINexus <[email protected]>

Part of the OBIX Heart/Soul UI/UX SDK monorepo.