TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

Low-level web programming in Racket and a wiki in 500 lines

135 点作者 ihodes将近 10 年前

7 条评论

mkozlows将近 10 年前
I'm glad to see someone talking about using the lower-level web libraries in Racket. The high-level continuation-based ones are ridiculously unsuitable for actual web programming (they store full state on the server at all times, and the URL gives you full access to the session, among other issues), but the lower-level ones actually look pretty clean and modern. And yet all the documentation keeps talking about the continuation stuff, bizarrely.
评论 #9717983 未加载
评论 #9718764 未加载
评论 #9719260 未加载
nosefrog将近 10 年前
This is very useful. I&#x27;m in the middle of a Racket web project right now and I got hung up on parsing&#x2F;processing form data. The Racket docs are very thorough, but they can be confusing if you don&#x27;t know what you&#x27;re looking for.<p>If anyone here has experience with web stuff in Racket, I&#x27;ve set up a small skeleton for Racket web projects: <a href="https:&#x2F;&#x2F;github.com&#x2F;samertm&#x2F;web-project-bootstrap.rkt" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;samertm&#x2F;web-project-bootstrap.rkt</a><p>Right now it contains skeletons for talking to sqlite, setting up a router and handlers, and manipulating the web server from the command line. I need to add an ORM (I&#x27;m not sure if Racket has any up-to-date ORMs?) and static file handlers. I&#x27;d love help or feedback!
评论 #9716921 未加载
评论 #9716662 未加载
baldfat将近 10 年前
Just being exposed to Racket last month I was extremely surprised at how well it clicked with me as opposed to Haskel which I tried to learn for a few months on my own and just tried out SML and it moved to Racket. Can&#x27;t put a finger on it but Racket just makes sense to me.
评论 #9716825 未加载
评论 #9717856 未加载
networked将近 10 年前
How fast is web-server&#x2F;servlet? Is it fit for production use?<p>Last time I checked (which was, admittedly, a long time ago) it served noticeably fewer &quot;hello, template world&quot; requests per second than Flask running on Python 2.7 while using more RAM. This was a pity to me because I thought Racket could otherwise be a very interesting language for web development.
59nadir将近 10 年前
Isn&#x27;t your `any?` function actually `ormap`[0]?<p>You should be able to do the same thing with:<p><pre><code> (ormap password-matches? line) </code></pre> 0 - <a href="http:&#x2F;&#x2F;docs.racket-lang.org&#x2F;reference&#x2F;pairs.html?q=ormap#%28def._%28%28lib._racket%2Fprivate%2Fmap..rkt%29._ormap%29%29" rel="nofollow">http:&#x2F;&#x2F;docs.racket-lang.org&#x2F;reference&#x2F;pairs.html?q=ormap#%28...</a>
评论 #9729671 未加载
cneu将近 10 年前
Very nice proof of concept. Just a word of warning: In practice you want to sanitize your input. The code in &quot;Serving static files&quot; allows to break out of document-root with &quot;..&quot;.
评论 #9719146 未加载
octatoan将近 10 年前
Hijacking: Can anyone tell me how to make a Scribble website have CSS like in HTDP?
评论 #9719281 未加载