zk/clojuredocs
zk/clojuredocs has 1,068 GitHub stars and 83 forks. GitHot measured 0 stars in 24 hours and 0 in 7 days. Last checked 2026-11-12 07:32 UTC. Last push 2023-11-09.
clojuredocs.org web app
측정된 스타 증가
- in 24h
- 0
- in 7 days
- 0
- in 15 days
- 기록 수집 중
- in 1 month
- 기록 수집 중
서로 겹치는 기간의 순증가량이며 일별 합계가 아닙니다. 측정값이 없으면 비워 둡니다. 스타는 관심도를 나타내며 품질을 보장하지 않습니다.
README.md
Originalclojuredocs
The clojuredocs.org webapp

Contributing
A few ways to contribute:
- Find & report bugs: https://github.com/zk/clojuredocs/issues
- Suggestions on how to make development on the site more friendly (docs, codebase organization).
Let's use GH issues for discussion for now
If you're looking for a project:
- Content for namespaces (see
src/md/namespaces) needs to be added / edited. Example of clojure.core.async - Listing of clojure training / classes / events on home page
- Stand-alone example page, maybe have the var info (signature, doc string, etc) at the top.
- Source-linking on libs not included in the standard library e.g. core.async.
Deploy
Production is deployed on an AWS t2.micro instance. There's an nginx process running on the box, balancing to two JVMs managed by Upstart to support zero-downtime deploys.
To regenerate the upstart scripts:
cd $REPO
sudo foreman export -a clojuredocs -e ./.env -u ubuntu -c "web=2" upstart /etc/init/
To start the app processes:
sudo service clojuredocs-web-1 start
sudo service clojuredocs-web-2 start
To redeploy:
# in $REPO
sudo service clojuredocs-web-1 stop
git pull origin master
# This will compile assets & run tests
bin/build
sudo service clojuredocs-web-1 start
# Wait for proc 1 to start serving requests
sudo service clojuredocs-web-2 restart
Reqs
- > JDK 7
- JCE Unlimited Strength Jurisdiction Policy Files
- lein
- foreman (see
Procfile,bin/dev) - less
- entr (available in homebrew)
- MongoDB
Dev
Run bin/dev, which will start all the things (repl, web process,
scss compiler, etc). See Procfile for more info.
Connect to the repl and / or visit http://localhost:4000
You'll notice that var information is already populated. In an effort to not make the same mistakes again, all core-related var info is loaded from the runtime version of Clojure on start up.
OTOH, examples, see-alsos, and notes (and any other user-generated content) are stored in the database.
Local Data
The app uses a MongoDB database named clojuredocs to store data. Run bin/db-reset to seed the database with a recent production export (you must be running mongod for this to work).
Prod Local
Occasionally you'll need to compile and run things as they would be in production (checking advanced cljs compilation, for example): bin/prod-local.
CLJS Source Maps
The ClojureDocs project is set-up to emit source-maps for compiled javascript. To enable in Chrome, check the 'Enable JS source maps' option in the Developer Tools settings pane.
Clojure Version
Clojure vars are pulled directly from the runtime, and are not stored in the database. When new versions of Clojure are released:
- Change the Clojure dep in
project.clj - Update the version string, source base url, and gh tag url in
clojuredocs.search/clojure-lib - Update the version for the mobile nav in
clojuredocs.pages.common - Update the github URL in
clojuredocs.pages.vars/source-url.
App Structure
Interesting files:
src/clj/clojuredocs/main.clj-- Main entry-point into the app, starts the jetty serversrc/clj/clojuredocs/entry.clj-- Root routes and middlewaresrc/clj/clojuredocs/pages.clj-- User-facing HTML pagessrc/clj/clojuredocs/api.clj-- API endpoints for ajax calls from the frontend.src/cljs/clojuredocs/main.cljs-- Main js entry-point into the app
Conventions
- Functions that return hiccup structures should be prefixed with a
$, like$layout. - Mutable state should be prefixed with a
!, ex:!my-atom.
Adding Functions, Macros, Special Forms, Namespaces & Other Vars
Most vars are picked up from Clojure at runtime, using core namespace
and var introspection utilities. Special forms and namespaces to
include on the site are specified explicitly in the
clojuredocs.search.static namespace.
Vars are picked up automatically based on the namespaces specified in
clojuredocs.search.static/clojure-namespaces vector. Any namespace
in this vector will be queried for public vars to be made searchable
and displayable on the site.
Special forms are specified in the
clojuredocs.search.static/special-forms list, and require a server
restart to be picked up in a dev environment.
Adding Core Libraries
Sometimes we'd like to add core libraries that are not part of the standard Clojure distribution (like core.async) to the site. Here's how to do that:
- Add dependency to
project.clj - Add ns sym to
clojure-namespacesinclojuredocs.search.static - Add a short description + links to community articles / videos /
other resources to
src/md/namespaces/
Dev-Prod differences
- Dev starts the environment using
lein repl :headless, prod useslein run -m clojuredocs.main. See:repl-optionsinproject.cljfor initialization options.
Data Exports
- See also relations (ns/name -> [ns/name]), results cached for 1 minute.
Contributors
Zachary Kim, Lee Hinman, and more.
License
Copyright © 2010-present Zachary Kim
Distributed under the Eclipse Public License either version 1.0 or (at your option) any later version.
관련 프로젝트 살펴보기
freeCodeCamp/freeCodeCamp
freeCodeCamp.org의 오픈 소스 코드베이스와 커리큘럼입니다. 수학, 프로그래밍, 컴퓨터 과학을 무료로 배울 수 있습니다.
459,018 스타donnemartin/system-design-primer
대규모 시스템 설계 방법을 배우고 시스템 설계 면접을 준비할 수 있습니다. Anki 플래시카드가 포함되어 있습니다.
377,640 스타react/react
웹과 네이티브 사용자 인터페이스를 위한 라이브러리.
252,535 스타vuejs/vue
Vue 2 저장소입니다. Vue 3은 https://github.com/vuejs/core를 방문하세요.
212,530 스타