-
Notifications
You must be signed in to change notification settings - Fork 10
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
webpack build thoughts #2
Comments
Hi Owen! Thanks for your feedback/additional links, very interesting stuff. Im interested in your thoughts about the webpack stuff, i'd happily take a look at a PR if you think it can be improved. (Especially interested in the viability of babel-preset-env) As for using express, it is a little overkill for what it's doing atm, but the point is to allow people to start quickly extending on this starter kit, and while I'd like to minimize some dependencies, the goal is not to have no dependencies at all. Also I feel like express is commonly recognized enough to warrant including it. |
I agree with this 100%. I really liked the fact that it had Express "built in", even with the extra config. |
Thanks for the feedback @thepassle and @aadamsx ! Looking forward to sharing. |
Hey @thepassle , here's where I've gotten so far in my efforts. OverviewHere is a branch with my latest WIP of a simple Todo App using LitElement
Here is some documentation I've written that can provide some more info. Basically without targetting IE11, there are no issues. Not sure what kind of browser support you had in mind. tl;drbrowserslist
babel
PostCSSmodule.exports = {
plugins: {
'postcss-cssnext': {},
'cssnano': {}
}
}; Polyfills<script src="https://cdnjs.cloudflare.com/ajax/libs/webcomponentsjs/2.0.2/custom-elements-es5-adapter.js"></script>
<script src="//cdnjs.cloudflare.com/ajax/libs/babel-polyfill/7.0.0/polyfill.js"></script>
<script src="//cdnjs.cloudflare.com/ajax/libs/webcomponentsjs/2.0.2/webcomponents-bundle.js"></script> Once i get all the browsers working, I would look to apply similar changes here. Looking forward to your thoughts! |
Hey owen! Finally have some time to really dive into this. The setup/config you have looks great, very clean. Im really looking to get rid of some dependencies and overall trying to have the build configuration much more clean, with as little means as necessary. My main concern is browser support, as of now CLA supports at least the latest 2 versions of all major browsers, though I think we should be able to get that up and running as well. I'll have more time to work on it this friday, i expect i'll have some more info by then. |
Fixed in d86159d Thanks for the feedback! :) |
Introductions 👋
First off, very cool project! I say that with all the envy and respect of someone who wishes they had thought of the idea first 😄
webpack Feedback
I'm still getting more familiar with the build and development workflows for "vanilla JS" projects with webpack in my own side project, but I have a fair amount of webpack experience with frameworks like Angular, React and Vue.
In reviewing I came out with a few observations for your consideration:
import
statements included from some point starting with theentry
point as this is how webpack is able to build up the dependency graph to fully optimize a build. Copying the files manually might negate the advantage webpack brings of being able to fully optimize and bundle / code split source files.import
in index.jsMisc Feedback
Happy to make a PR if you're onboard with these changes! ✌️
The text was updated successfully, but these errors were encountered: