Closed danielstaleiny closed 3 years ago
@danielstaleiny I want to keep CMS', CSS, and JS frameworks out of this starter so it's bit more of a baseplate, but I would love to hear about the caching issues you fixed in dev, as well as:
serve to test in production
Well, there wasn't any issue. I was just thrown away be fact that it cached js and css I think. I really don't need caching in dev so I re-configured it to cache images only, instead. (I also never worked with workbox so, that is why)
also you were missing theme definition for PWA
<meta name="theme-color" content="white"/>
By serving production to test. I just meant adding
"serve": "serve -l 3000 dist"
To make sure that everything works as desired in prod, and you can check that all the files are minified and what not.
Also I had issue loading browser-sync. so I added it in dev.
{% if config.env === 'development' %}
{% include "partials/browser-sync.dev.njk" %}
{% endif %}
<script id="__bs_script__">//<![CDATA[ document.write("<script async src='http://HOST:3000/browser-sync/browser-sync-client.js?v=2.26.3'><\/script>".replace("HOST", location.hostname));
//]]></script>
I get that you don't want to include CMS, CSS and JS frameworks to this project. I agree totally, but perhaps make a new branch with each of them and all of them together. as starter. and point to them in README.md
also I would definitely add prettier to this project. (my opinion, you do you)
I was also thinking adding storybook with html templates(shortcodes) and just document them, because we don't really care about size of the template folder, we can just add as many as we want while keeping it maintainable. If you don't loaded it, it will not be in the website anyway. Just a thought. Same for certain predefine styles, typography for blog, typography for general website. and you can just plug what you need. I also understand that it should be as simple as possible so adding additional stuff will confuse newcomers. But in different branch, why not ?
Once you have all of this, you make generator to automatically make a project and you can cherry pick what you want for a project. or you can make single generator with all the stuff and have global config file where you toggle features you want or you don't want. once compiled it will be as minimalist as you need.
@danielstaleiny thanks for the feedback!
I'm more than happy to add forks of this project to the readme, if you wanted to setup a more wholistic starter.
One thing I do plan on adding is Netlify one-click deploy support, as well as the new Netlify dev environment, which will give you the production serving you're looking for.
I'd also like to add instructions for:
In order to make picking up 11ty and more specifically, parceleventy, easier.
As for prettier, autoformatting is great if you ask for it. For beginners, it's extremely jarring. I will however add an editorconfig to this project.
@danielstaleiny also on your service worker caching issue -- absolutely.
I think this setup needs a better default service worker that handles cache invalidation.
I just wanted to say thank you for creating this awesome boilerplate. I was thinking about making template like this anyway, so you saved me a lot of time.
I had some spare time during a weekend and I added stuff which I like to use. Notably:
you can have a look https://github.com/danielstaleiny/parceleventy
if you want me to make pull request with some of the stuff I added let me know.
Oh, and I want to make generator out of this, so you can opt out from some of the features and quickly create project.