-
Notifications
You must be signed in to change notification settings - Fork 434
Please provide a min.js file the NPM package #40
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
Comments
I'm not sure providing minified version since vue-class-component only provide for the commonjs build. |
I personally prefer a minified version to keep my build process complexity low(er). A modern JS build setup tends to get big and complex, even for small apps. One of the selling points of Vue is how easy it is to get started. Add the script and you can start coding. A minified commonjs and browserified file would be helpful. It keeps in line with Vue itself and makes it easier to consume this library. Choice is always good :) |
@cbruun hmm I think you might have some misunderstanding of how this works - as for now decorator is not even part of the spec (stage 2), the only way you can use it is with a build step via Babel or TypeScript. Also ES2015 classes are only supported in latest browsers if you don't use a build step. A minified version just don't make much sense in this situation. |
I see your point. In my case I am using TypeScript and bundling it with Rollup. I am not using the CommonJS version of Vue, as it adds about 2 seconds of extra crunch time for Rollup. VueJS has a small footprint, so I won't get much from tree shaking it. I'd rather have the fast compile time. vue-class-component only works with the Vue CommonJS bundle, as the regular bundle does not have a default export of Vue (as in Vue['default'] is undefined). I just wanted to be able to add the scripts tags for Vue and vue-class-component and write my TypeScript app without dealing with CommonJS. |
It makes sense to me. I'll add umd and minified umd build from next version. |
@cbruun On v4.4.0 or later, you can use minified build on |
@ktsn Thank you :) |
I think it makes sense for this library to provide a min.js file, just like Vue does it.
The text was updated successfully, but these errors were encountered: