HNHacker News
TopNewBestAskShowJobs

ashtonjamesd

195 karma · joined October 9, 2025

Fanatical C Developer
submissionscomments
ashtonjamesd··on Show HN: I built a web framework in C
No problem! With C, I started with the K&R book. This provided a great foundation for C and some fundamental CS concepts. I am unsure of the best way to obtain a more structured curriculum outside of college, as that is how I received mine. There are many YouTube video courses to choose from if that is the type of content you learn best from. And many for CS fundamentals. I would also highly recommend a combination of project-based learning with theory, as that will accelerate your understanding quite a bit. You could try looking for a programming buddy on Reddit on r/programming, too! Having someone at a similar skill level to you will make learning easier as you both share knowledge.
ashtonjamesd··on Show HN: I built a web framework in C
Thank you for the feedback! I agree it does obfuscate the signature, possibly too much. I think it's okay as long as the user has the option to do both, with this made clear in the docs.

Also, yes I agree, RequestContext makes more sense!

ashtonjamesd··on Show HN: I built a web framework in C
Hi, I have been coding on GitHub for about 2 years. There's no trick other than enjoying it and relentlessly programming for fun. You probably know this, but if you enjoy something, you'll likely be better at it than someone who doesn't! More concrete advice would be to become an expert on the fundamentals and then try to tackle large projects, things that you think you could definitely not do, but do them anyway.
ashtonjamesd··on Show HN: I built a web framework in C
That's a very good idea actually and I had wanted to do that but it didn't click that you could do that with a macro!

Thank you, I'll will implement that :)

ashtonjamesd··on Show HN: I built a web framework in C
Thank you, I really appreciate you saying that!

Yes it's on the backlog and will be fun to implement :)

ashtonjamesd··on Show HN: I built a web framework in C
Thank you for the feedback, it is appreciated!

I did intend to implement parallelization as a later feature so it's good to bring it up.

ashtonjamesd··on Show HN: I built a web framework in C
Yes, I'm sure that is something I can add to it.

I will add it to the backlog of things to do :)

ashtonjamesd··on Show HN: I built a web framework in C
Haha, the example could be better. All of the other things combined, I would say it could be called a framework.

There are some more examples in doc/

ashtonjamesd··on Show HN: I built a web framework in C
Thank you, that means a lot! :)
ashtonjamesd··on Show HN: I built a web framework in C
Wow! That really means a lot because I always make a lot of effort to make sure my code is just that :)

Appreciate you saying that!

ashtonjamesd··on Show HN: I built a web framework in C
Thank you so much! I appreciate it :) And yes, totally agree.
ashtonjamesd··on Show HN: I built a web framework in C
Haha, I have used AI in some parts of it - mainly the JSON part because I could not wrap my head around it for the life of me. But I am proud that 90% is self written!
ashtonjamesd··on Show HN: I built a web framework in C
No of course not, I understand where they are coming from in all honesty. Thank you that means a lot!
ashtonjamesd··on Show HN: I built a web framework in C
That's amazing to hear and motivates me to solidify the framework further. I appreciate you showing interest! :)

I'd love to hear about your project when you get round to it.

ashtonjamesd··on Show HN: I built a web framework in C
That's fair. And I do agree. The use cases for something like this are very thin compared to what tools you can use out there instead, Django, Rails, Express, etc. All of which offer a much safer development experience. However, I still believe it will have a use case for some.
ashtonjamesd··on Show HN: I built a web framework in C
True. Also, I love the C language and I don't get joy out of writing in many other languages. Additionally, I've wanted to make something like this just to learn more about how web servers work. I appreciate your thoughts.
ashtonjamesd··on Show HN: I built a web framework in C
Hi, sorry maybe I should've added a comment for that.

The 'appRoute' is a macro that expands to a function signature.

The macro is: '#define appRoute(name) HttpResponse name(AppContext ctx)' and the parameter I passed as 'home' is expanded into the function name. The reason is because all controller function signatures are the same, so just writing 'appRoute' allows the developer to save time writing endpoints!

It is a tradeoff between readability and development speed. And one of the ideas behind the framework is succint and minimal code.

ashtonjamesd··on Show HN: I built a web framework in C
C finds a way.
ashtonjamesd··on Show HN: I built a web framework in C
Right now, it's just a framework for building backends. So yes, server-side applications. However, I have thought about implementing a templating engine for serving HTML files.
ashtonjamesd··on Show HN: I built a web framework in C
For fun! And because I wanted to create a framework that makes coding in C feel like a high level language (mainly for fun though).