Live data from Hacker News

VuePress: a static site generator that excels at working with documentation

forestry.io

11–20 of 39 posts

Re: VuePress: a static site generator that excels at working with documentation

#11
post #10
post #6

Earlier quoted context omitted.

How much vue do you need to know to heavily customize a theme?

Not much at all, all .vue files in the components directory gets registered globally, so if you create a Navbar.vue file, you can use anywhere in your theme. Easiest templating system I've ever used. If you learn a bit of how passing props work, you're golden! Some info on vue single file components: https://vuejs.org/v2/guide/single-file-components.html Props documentation: https://vuejs.org/v2/guide/components-prop…

Do you know if registered globally = pre-loaded or are they only loaded as encountered / needed? Just wondering if you have to be careful how many components you put in that directory. Not for purpose of templates of course, but for the unique Vue components that you can put in page content.

Re: VuePress: a static site generator that excels at working with documentation

#12
All these static site "generators" seem pretty silly. If you're going to make a static site then just make a few template pages by hand in html then copy and edit them to fill with whatever content.

It works even better if your webserver has server side includes (SSI) turned on. Then you can make header/footer/sidebar/etc templates and just insert them with a line in the page templates.

Re: VuePress: a static site generator that excels at working with documentation

#13

All these static site "generators" seem pretty silly. If you're going to make a static site then just make a few template pages by hand in html then copy and edit them to fill with whatever content. It works even better if your webserver has server side includes (SSI) turned on. Then you can make header/footer/sidebar/etc templates and just insert them with a line in the page templates.

This. This and Jekyll. Jekyll is good too.

Re: VuePress: a static site generator that excels at working with documentation

#14

All these static site "generators" seem pretty silly. If you're going to make a static site then just make a few template pages by hand in html then copy and edit them to fill with whatever content. It works even better if your webserver has server side includes (SSI) turned on. Then you can make header/footer/sidebar/etc templates and just insert them with a line in the page templates.

If that works for you, great! But just because you’re not the target audience doesn’t mean it’s silly.

I just have a simple site, but I know I don’t want to write my content in HTML. I just want to write it in Markdown and be on my way. Having yaml frontmatter for metadata and markdown for the body let’s me keep my content separate from my templates.

On the other end of the spectrum are larger organizations like Borisfx.com building large multimedia static sites. Or hell, look at the Forestry.io website and then tell me a few simple templates made by hand would suffice.

Re: VuePress: a static site generator that excels at working with documentation

#15

All these static site "generators" seem pretty silly. If you're going to make a static site then just make a few template pages by hand in html then copy and edit them to fill with whatever content. It works even better if your webserver has server side includes (SSI) turned on. Then you can make header/footer/sidebar/etc templates and just insert them with a line in the page templates.

Just out of curiosity, why? Why would I want to do so much more work?

Re: VuePress: a static site generator that excels at working with documentation

#16

All these static site "generators" seem pretty silly. If you're going to make a static site then just make a few template pages by hand in html then copy and edit them to fill with whatever content. It works even better if your webserver has server side includes (SSI) turned on. Then you can make header/footer/sidebar/etc templates and just insert them with a line in the page templates.

Because one of the things that keeps people engaged in maintaining a website is being able to fiddle with it, and the cost of fiddling with the layout of a truly static site is a lot higher than intuition would suggest.

Because you have to take the odds of making a stupefying, drop-everything mistake on any one page and take it to the nth power. That’s O(c^n). That’s an order of complexity that I haven’t even bothered contemplating in so long that I had to look up the notation.

Re: VuePress: a static site generator that excels at working with documentation

#17

VuePress pulls in nearly a thousand transitive dependencies. In light of recent security incidents[0][1] and the relative ubiquity of poor security practices[2] in the npm ecosystem, that seems like an unacceptably large attack surface. I don't want to have to worry about somebody injecting malicious code or cryptocurrency miners into my website by compromising a little-watched transitive dependency in my static site…

But this is a static site generator. They can't take over your server if you're just serving up stuff from S3.

Re: VuePress: a static site generator that excels at working with documentation

#18
post #17

VuePress pulls in nearly a thousand transitive dependencies. In light of recent security incidents[0][1] and the relative ubiquity of poor security practices[2] in the npm ecosystem, that seems like an unacceptably large attack surface. I don't want to have to worry about somebody injecting malicious code or cryptocurrency miners into my website by compromising a little-watched transitive dependency in my static site…

But this is a static site generator. They can't take over your server if you're just serving up stuff from S3.

They can't take over your server but they can inject a script tag with a cryptominer for all of your users to run. It's not the end of the world because you're just out a few dollars in electricity but it would be embarrassing.

Re: VuePress: a static site generator that excels at working with documentation

#20
post #17

VuePress pulls in nearly a thousand transitive dependencies. In light of recent security incidents[0][1] and the relative ubiquity of poor security practices[2] in the npm ecosystem, that seems like an unacceptably large attack surface. I don't want to have to worry about somebody injecting malicious code or cryptocurrency miners into my website by compromising a little-watched transitive dependency in my static site…

But this is a static site generator. They can't take over your server if you're just serving up stuff from S3.

True, but they can compromise the machine that runs VuePress (or at least, run arbitrary userlevel JS code on it).
Post reply on HN