Socket
Socket
Sign inDemoInstall

@jsdocs-io/extractor

Package Overview
Dependencies
85
Maintainers
1
Versions
14
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    @jsdocs-io/extractor

The API extractor for npm packages powering jsdocs.io


Version published
Weekly downloads
206
increased by30.38%
Maintainers
1
Created
Weekly downloads
 

Readme

Source

@jsdocs-io/extractor

Build status Coverage jsDocs.io Language npm License

This is the API extractor powering jsDocs.io.

It downloads packages from the npm registry and analyzes them to extract their public API.

Requirements

  • Bun must be installed to resolve and install packages

API & Package Info

Usage Examples

[!WARNING] Analyzing packages is a blocking operation that requires some time, even seconds, to finish! Using workers is recommended.

  1. Analyze the latest version of the preact package from the npm registry:
import { extractPackageApi } from "@jsdocs-io/extractor";

(async () => {
	const packageApi = await extractPackageApi({ pkg: "preact" });
	console.log(JSON.stringify(packageApi, null, 2));
})();
  1. Analyze a specific subpath export, like preact/hooks:
import { extractPackageApi } from "@jsdocs-io/extractor";

(async () => {
	const result = await extractPackageApi({ pkg: "preact", subpath: "hooks" });
	console.log(JSON.stringify(packageApi, null, 2));
})();

License

AGPL-3.0-or-later

Copyright (C) 2024 Edoardo Scibona. See LICENSE.

This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more details.

You should have received a copy of the GNU Affero General Public License along with this program. If not, see https://www.gnu.org/licenses/.

Keywords

FAQs

Last updated on 05 Mar 2024

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc