-
Notifications
You must be signed in to change notification settings - Fork 34
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Installing as dependency (instead of devDependency) makes final bundle big #180
Comments
Hm, great point. If you use I think removing |
This is one potential fix to google#180 that allows schema-dts to continue to be used with `import` and any/no bundlers without increasing bundle size. It is also possible to address google#180 by simply asking users to save schema-dts as a dev dependency. This is generally more correct for typings, but runs the risk of leaving dangling imports to nonexistent "schema-dts" js. We _may_ want to add TypeScript as a dev dependency instead. I'm not sure.
This is one potential fix to google#180 that allows schema-dts to continue to be used with `import` and any/no bundlers without increasing bundle size. It is also possible to address google#180 by simply asking users to save schema-dts as a dev dependency. This is generally more correct for typings, but runs the risk of leaving dangling imports to nonexistent "schema-dts" js. We _may_ want to add TypeScript as a dev dependency instead. I'm not sure.
This change is required to use schema-dts in a serverless setting like deno-deploy, since including the 38MB of typescript makes the bundle size prohibitive. Any update on when this will be released? |
I noticed that this library lists
typescript
as a peer dependency in the package.json. At the same time, the README suggests installing this library by doingnpm install schema-dts
.What happens then is that when I generate the bundle for my server, this library and also
typescript
are being bundled together with my server code, making the bundle quite big (typescript
alone is 3MB minified).Am I doing something wrong? Or should this library be installed as a
devDependency
instead?The text was updated successfully, but these errors were encountered: