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

babel-plugin-jsdoced

v1.2.4

Published

It implements jsdoced javascript as a babel plugin

Readme

babel-plugin-jsdoced

a babel plugin which use jsdoc to implement strong typing in javascript It implements the principle of jsdoced javascript as a babel plugin. It implements strong typing for functions in javascript. The type of the function arguments and of the return value are checked according to your jsdoc. It is working in browser and node.js. it has source maps.

On top of it it supports es6 arrow functions too! If you use react, don't worry it works with jsx without trouble.

Check it out! How to install it

What is JSDoced Javascript ?

Here is a Youtube video "JSDoced JS in 1min", it worth the whole minute :)

or in a single image

jsdoced javascript in a single image

Features

  • no dependancies
  • works in node.js and browser
  • support source maps
  • works with es2015 and react/jsx
  • even works with new es6 arrow function
  • easily integrable in modern js tools. browserify/webpack/gulp you name it

Use cases

  • Improve your tests
    • jsdoced javascript will detect a new kind of errors.
    • So this is an additional level of testing
    • better detect those bugs before your users see them :)
  • Debug build for library
    • any library provide a minified version and a normal version
    • You can provide a jsdoced version
    • this debug version contains additional code to help debug.
    • thus people can use this one when developping or testing their own project
    • and hopefully detect errors earlier.
    • Specially interesting when you are learning a library. because you are more likely to do mistakes. better for your users :)
    • see /examples/gulpfile for a example on how to that with gulp

Installation

$ npm install babel-plugin-jsdoced

Usage

Via .babelrc (Recommended)

.babelrc

{
  "plugins": ["jsdoced"]
}

With es6

{
  "presets": ["es2015"],
  "plugins": ["jsdoced"]
}

Via CLI

$ babel --plugins jsdoced script.js

With es6

$ babel --presets=es2015 --plugins jsdoced ./sample-es6.js

Via Node API

require("babel-core").transform("code", {
  plugins: ["jsdoced"]
});