Skip to content

Include only needed files to npm package #52

@rubiesonthesky

Description

@rubiesonthesky

Hi!

It seems that this package is 444 kB by npm's report.

I think there are a lot unnecessary files included in the published package: https://www.npmjs.com/package/@lezer/markdown?activeTab=code

For example

  • .mocharc.cjs
  • CHANGELOG.md (could be included, but could be just linked to repo)
  • build.js
  • rollup.config.js
  • tsconfig.json
  • test dir
  • bin dir only includes build-readme script?
  • src/README.md seems same as ./README.md?

So only files that should be included in ´files` section in package.json seem to be

  • dist
  • README.md
  • package.json

There may be other files to be included depending on your preferences. But I think usually only these files are needed :) That probably about halves the package size.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions