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

@svmukhin/comprehensible-wsdl

v0.1.0

Published

Generate a readable HTML5 reference page from a WSDL file

Readme

comprehensible-wsdl

Generate a readable, self-contained HTML5 reference page from a WSDL file.

npx comprehensible-wsdl service.wsdl -o docs.html

The output is a single HTML file styled by edible-css — no classes, no build step, no JavaScript required.


What gets documented

| WSDL concept | What the HTML shows | | ------------ | -------------------------------------------------------------------------------------- | | Service | Name, target namespace, documentation | | Types (XSD) | Each complexType / simpleType / element with fields, types, and allowed values | | Operations | Name, documentation, input and output fields expanded inline, faults | | Bindings | Protocol (SOAP 1.1 / 1.2), style (document / rpc), transport, SOAPAction per operation | | Endpoints | Service name, port name, binding, URL |

Operations inline-expand their input / output messages so you see field names, types, and constraints without jumping between sections.


Installation

# One-off with npx (no install required)
npx comprehensible-wsdl service.wsdl -o docs.html

# Global install
npm install -g comprehensible-wsdl
comprehensible-wsdl service.wsdl -o docs.html

# Local project install
npm install --save-dev comprehensible-wsdl
npx comprehensible-wsdl service.wsdl -o docs.html

Requires Node.js ≥ 20.


Usage

Usage: comprehensible-wsdl [options] <wsdl-file>

Arguments:
  wsdl-file            Path to .wsdl / .xml file, or "-" to read stdin

Options:
  -V, --version        output the version number
  -o, --output <file>  Write HTML to file instead of stdout
  --title <string>     Override the page <title>
  --inline-css         Embed edible.css inline (fully offline output)
  -h, --help           display help for command

Examples

# Write to a file and open in the browser
comprehensible-wsdl service.wsdl -o docs.html && xdg-open docs.html

# Print to stdout and pipe into a browser tool
comprehensible-wsdl service.wsdl | browser-sync start --file docs.html

# Read from stdin (e.g. from curl)
curl https://example.com/service?wsdl | comprehensible-wsdl - -o docs.html

# Override the page title
comprehensible-wsdl service.wsdl --title "Payment API Reference" -o docs.html

# Fully offline output — embed edible.css in the HTML file
comprehensible-wsdl service.wsdl --inline-css -o docs.html

Import resolution

The tool resolves <xsd:import>, <xsd:include>, and <wsdl:import> elements automatically:

  • Local paths — resolved relative to the directory of the WSDL file.
  • HTTP / HTTPS URLs — fetched at generation time using the built-in fetch().
  • Circular imports — detected and skipped.
<!-- These are resolved automatically -->
<xsd:import schemaLocation="./types/shared.xsd"/>
<xsd:import schemaLocation="https://example.com/common-types.xsd"/>
<wsdl:import location="./auth.wsdl"/>

HTML output structure

The generated page uses only semantic HTML5 elements, which edible-css styles without any classes:

  • <details> / <summary> — collapsible type definitions
  • <table> — fields, message parts, bindings, endpoints
  • <article> — one per operation
  • <blockquote><wsdl:documentation> text
  • <code> — type names, namespaces, SOAPActions, URLs
  • <mark> — required fields (minOccurs ≥ 1)
  • <nav> — in-page anchor links to each section

Styling

By default the page links to the edible-css CDN:

<link
  rel="stylesheet"
  href="https://cdn.jsdelivr.net/npm/@svmukhin/edible-css@latest/dist/edible.min.css"
/>

To produce a fully self-contained file with no external dependencies, use --inline-css. The CSS is fetched once at generation time and embedded in a <style> tag.


Architecture

bin/cli.js          Command-line entry point (commander)
src/
  parse.js          XML string → raw JS object (fast-xml-parser)
  model.js          Raw object → normalised model
  resolve.js        Cross-reference resolution (message → type → fields)
  render.js         Model → HTML string
  load.js           Async loader: resolves xsd:import / wsdl:import recursively
  util.js           Shared helpers (stripNs, text, arr)
test/
  fixtures/         Sample WSDL and XSD files used by tests
  *.test.js         Unit and integration tests (node:test)

Development

# Install dependencies
npm install

# Run all tests
npm test

# Run a single test file
node --test test/model.test.js

# Lint (oxlint)
npm run lint

# Format in place (Prettier)
npm run format

# Check formatting without writing (useful in CI)
npm run format:check

Tests use the built-in node:test framework — no extra test runner needed.


License

MIT