←back to thread

82 points jaysylvester | 1 comments | | HN request time: 0.206s | source

Citizen is a web application framework I started building years ago when I was first learning Node. I've added features and improved stability/performance continuously and finally decided it was worthy of 1.0 status.

I think it might appeal to devs like me (old guys) who came up on app servers like ColdFusion, .NET, PHP, etc. and prefer the server do the heavy lifting. It doesn't dictate anything about your front end, and instead tries to be as flexible as possible in providing whatever output the client might need, whether it's a single fully-rendered HTML view, partials, JSON, or plain text.

Only 2 direct dependencies for terminal commands (commander) and file watching (chokidar). Built-in functionality includes zero-configuration server-side routing, session management, key/value store (cache rendered views, controller actions, objects, and static files), simple directives for managing cookies, sessions, redirects, and caches, and more.

It's been in continuous use on at least one site that receives hundreds of thousands of page views per month, running months at a time without the process crashing. Fairly stable.

Appreciate any comments/feedback/contributions.

Show context
korkybuchek ◴[] No.41863143[source]
Are there any tests for this library? And it looks like you don't support Typescript, is that planned?
replies(2): >>41863349 #>>41866242 #
jaysylvester ◴[] No.41863349[source]
No tests yet, that's been on my list since the beginning and I now have the incentive to work on them:

https://github.com/jaysylvester/citizen/issues/24

I don't use TypeScript myself, but based on what I know, I don't think it would be difficult to add support. I just opened an issue to track it:

https://github.com/jaysylvester/citizen/issues/131

replies(1): >>41864069 #
mrcwinn ◴[] No.41864069[source]
"No tests yet, been on my list." This truly is fitting within classic software norms. Bravo.
replies(1): >>41864102 #
1. jaysylvester ◴[] No.41864102[source]
At least I stopped deploying site updates via FTP.