Live data from Hacker News

How to build a website without frameworks and tons of libraries

kodingkitty.com

151–160 of 270 posts

Re: How to build a website without frameworks and tons of libraries

#151

Earlier quoted context omitted.

Jinja is a templating framework. You can use it with ansible for example, to replace config values or secrets in a configuration file for different servers, etc

after some research i now know that, but there was no clear link or description of what the heck was going on

Well, it is a decade-and-a-half old and fairly common in the Python web world. I don't think there's any shame in not knowing what it is if you haven't encountered it, but I also don't think there's any shame in assuming a developer audience reading about web development would at least know how to figure out what it is.

Re: How to build a website without frameworks and tons of libraries

#152
post #62

Earlier quoted context omitted.

> First, your dark mode is implemented wrong in the lazy corner-cutting way of doing JS post-load ... I agree with your whole comment, but the media query approach is also tricky. You typically still want to offer a toggle while respecting prefers-color-scheme, and you may want to give priority to whatever choice the user has made with that toggle if they've used it on your site before. This still requires JS and loc…

This still requires JS and localstorage. I've been considering this recently for my site and I settled on having prefers-color-scheme on the root domain with dark. and light. subdomains. If the user chooses a color they just get bumped to a subdomain that sets a cookie with their preference. If they come to the site from an external link and they have a preference cookie they get redirected to the subdomain again. Ab…

I don't know whether to be fascinated or horrified by this proposal, but I admire the novelty - I can definitely say that in all the dark-mode proposals/implementations I've looked at over the years we've been fiddling with ours, I've never seen that suggested.

Re: How to build a website without frameworks and tons of libraries

#153

Earlier quoted context omitted.

Take a deep breath and go for a walk, there's no reason an inconsequential blog post should make you this angry.

[flagged]

The writer was belittling the OP so maybe direct that elsewhere

Re: How to build a website without frameworks and tons of libraries

#154
post #103

Alright, I’m gonna be that guy. Right now, sveltekit + skeleton has absolutely blown my mind at how fast you can make a usable prototype. It’s honestly insane. You don’t even need to know svelte, really. As long as you can understand the file based routing thing, the rest is just html unless you really need more. Especially with the tailwind stuff built right in and a mostly vanilla looking theme. I’ve tried probably…

SvelteKit is amazing. I disagree about Skeleton though. Skeleton makes you feel productive and safe at first but it has a lot of foot-guns. It leads you down a happy path until you don't like something and then it's difficult to customize. You're much better off using DaisyUI or something headless like MeltUI when it's ready. Take a look at Skeleton's own site https://www.skeleton.dev/docs/get-started Press page down…

My wife does UX. I showed her Skeleton and she launched into listing all their UX mistakes on their website...

Re: How to build a website without frameworks and tons of libraries

#155
Frameworks and libraries should not be limited by ideology. The primary objective should be to utilize whatever is necessary to achieve the task at hand. And no more!

When creating websites, the focus should not be on competing to use the fewest (or most) number of tools, but rather on effectively serving users and ensuring their satisfaction.

*User experience should be the guiding principle.*

What concerns me about this article is their simplistic view that using a minimalist stack is solely a matter of choice, without acknowledging the nuances involved. It comes across as arrogant.

Furthermore, their demonstration of "building a website without frameworks and numerous libraries" is based on their own website, which is nothing more than a static landing page with links to blog posts.

Could anyone realistically build an Uber or an Airbnb using the same approach, even if they wanted to?

Re: How to build a website without frameworks and tons of libraries

#156
post #103

Alright, I’m gonna be that guy. Right now, sveltekit + skeleton has absolutely blown my mind at how fast you can make a usable prototype. It’s honestly insane. You don’t even need to know svelte, really. As long as you can understand the file based routing thing, the rest is just html unless you really need more. Especially with the tailwind stuff built right in and a mostly vanilla looking theme. I’ve tried probably…

This is a great recommendation. I'm interested in hearing more of your experiences trying different web frameworks. Did you try Flutter as well?

I haven’t tried flutter! It looks interesting, but I don’t have much interest in learning Dart so it’s pretty low on the list of things to try, for me. I have experience with Capacitor and Vue, which kind of accomplishes the same cross platform thing, although I wouldn’t really recommend it.

Another one I tried was Hugo, but I also didn’t bond with it. I found Go makes it so tough to have your templates be properly reusable if you stick to only the standard library template engine.

Re: How to build a website without frameworks and tons of libraries

#157
post #121

Earlier quoted context omitted.

They don't want to use a framework so they wrote their own framework that is most likely shittier and more impossible to debug. Also, now they have to train all their new engineers on their own home-grown shitty/impossible-to-debug framework.

How is a 45 line python script that runs templates hard to debug? You’re calling something “most likely” shitty, but have you seen it? Used it? I find this post and the method they use to produce their site utterly refreshing. What is “shitty” is many dozens (being kind) of JS libraries, complex configurations, and learning multiple tools to produce the same result!

Also many frameworks get over bloated and complicated because they’re trying to solve problems for everybody and edge cases that might not interest you. A lot of times you can get some ideas from it and build something simpler.

Re: How to build a website without frameworks and tons of libraries

#158
post #121

Earlier quoted context omitted.

They don't want to use a framework so they wrote their own framework that is most likely shittier and more impossible to debug. Also, now they have to train all their new engineers on their own home-grown shitty/impossible-to-debug framework.

How is a 45 line python script that runs templates hard to debug? You’re calling something “most likely” shitty, but have you seen it? Used it? I find this post and the method they use to produce their site utterly refreshing. What is “shitty” is many dozens (being kind) of JS libraries, complex configurations, and learning multiple tools to produce the same result!

There’s a certain irony in calling this approach “hard to debug” vs. a library like React with its hooks implementation.

Re: How to build a website without frameworks and tons of libraries

#159
post #103

Alright, I’m gonna be that guy. Right now, sveltekit + skeleton has absolutely blown my mind at how fast you can make a usable prototype. It’s honestly insane. You don’t even need to know svelte, really. As long as you can understand the file based routing thing, the rest is just html unless you really need more. Especially with the tailwind stuff built right in and a mostly vanilla looking theme. I’ve tried probably…

SvelteKit is amazing. I disagree about Skeleton though. Skeleton makes you feel productive and safe at first but it has a lot of foot-guns. It leads you down a happy path until you don't like something and then it's difficult to customize. You're much better off using DaisyUI or something headless like MeltUI when it's ready. Take a look at Skeleton's own site https://www.skeleton.dev/docs/get-started Press page down…

This is good to know! I’ll try out DaisyUI next! My favourite part about skeleton has been having mostly functional, pre-existing component classes. The svelte material ui (smui?) library left a lot to be desired there, and I like how easy it is the modify the skeleton ones, since they aren’t a horrible jumbled mess of tags like all of the Vuetify components are below the surface.

My least favourite part of tailwind is needing a stock button and having to add 80 characters worth of class stuff just to get a generic looking button, which is what skeleton solves for me.

Re: How to build a website without frameworks and tons of libraries

#160

> Mind you, Hetzner webhosting starts at 2 EUR! How crazy is that? Oh yeah? and netlify is totally free for an infinite amount of sites! how crazy is that? > We use a short Python script with exactly 45 lines of code. Including comments and blank lines. > > In summary, this is the simple toolchain for building our web: > > Developer updates index.src.html > Watchdog.py detects the file change and ... > ... renders Ji…

> Meet Jinja templates, which make our life much easier. Jinja allows us to use loops, include files (navigation bar, footer, etc.) and much more.

> no description of what Jinja - I for one don't know what either of those are, sorry if i'm an "ignorant normie"

The first mention of Jinja had both a description of what it does for them, and a link that you could have clicked to get more information about it. Guess it's easier to post snarky comments on HN.

Post reply on HN