web icon indicating copy to clipboard operation
web copied to clipboard

Try on local packages?

Open mighdoll opened this issue 9 months ago • 3 comments

It'd be nice to iterate on my package and see how the docs look w/o having to publish to npm with each change..

Is there a way to try a local build of jsdocs-io on unpublished packages?

mighdoll avatar Apr 11 '25 23:04 mighdoll

Hi @mighdoll, thanks for the issue!

Currently there isn't a way as the main focus is on published npm packages. However, I've run some test and it should be feasible to support analyzing local packages generated with npm pack.

The process should look like this:

  1. Author: Write code
  2. Author: Build step (e.g., npm run build)
  3. Author: Generate package (i.e., npm pack)
  4. Local jsdocs.io instance: Analyze package.tgz

It could be done by navigating for example to localhost:3000/local/path/to/my/package.tgz where local is the endpoint for local packages followed by the absolute path of the package tarball.

velut avatar Apr 14 '25 16:04 velut

That would be great! It'd be nice to be able to view doc changes locally before npm publishing a new rev.

... I think you're suggesting that jsdocs-io could work that way, not that it already does. I gave it a quick try and it didn't work for me yet.. but if it's supposed to work already, I'll try again.

mighdoll avatar Apr 14 '25 19:04 mighdoll

It's not implemented yet.

velut avatar Apr 14 '25 20:04 velut