oakes / dynadoc Goto Github PK
View Code? Open in Web Editor NEWDynamic documentation for Clojure(Script)
License: The Unlicense
Dynamic documentation for Clojure(Script)
License: The Unlicense
I'm using Dynadoc for a project, and most of the functions work fine, but some have strange definitions i.e. for camel-snake-kebab.core
, functions are documented as (->Camel_Snake_Case s__44602__auto__ & rest__44603__auto__)
. Is there a fix for this, or is it an issue with that dependency?
Hey Zach,
to be honest I have never used your project but I came here since it was mentioned in an expound
issue.
I checked your docs generation and they seem really nice, which made me wonder if you have considered creating examples automatically.
You are already creating docs automatically so why not the examples? ๐
With the introduction of clojure spec it is possible to "instrument" functions and through that both arguments and return values can be determined.
Since it is (generally) possible to get a generator for a clojure spec I think it should be possible to generate an example based on an instrumented function
Hope it helps
I'm assuming this will play nice with rum.
I wasn't able to follow the code in the defexample macro, so I'm not sure what arguments it takes in full. My example so far looks like this:
(defexample example.core/click-counter
{:with-card card}
(rum/mount (click-counter) card))
And on the dynadoc page, which renders fine (I'm back to using figwheen atm), it's saying "rum.mount is not a function" on the page. Which I'm not sure how to understand, as it's certainly is one according to the rum docs.
If I fire up a new dynadoc I get a list of all the namespaces and it's hard to find a page that is relevant to the project. This includes clojure core and all the libs. It would be nice if there was filters for clj core, libs, and local nses.
I started the UI work on this, but I'm struggling with the ns filtering logic.
Core is easy enough to detect with patterns matching.
I'm not sure how to detect library namespaces and local.
http://clojure.github.io/tools.namespace there is some functions there that could help.
greetings, This I'm trying to use dynadoc from shadow-clj. I hit a snag when i try to compile the docs application which is very small
(ns docs
(:require [tomatto.frontend.app :as app]
;; must require dynadoc.core so dynadoc's frontend can be built
dynadoc.core
[rum.core :as rum])
(:require-macros [dynadoc.example :refer [defexample]]))
(defexample basic-deps-cljs.core/clicks
{:with-card card
:with-focus (app/Text {:size "14px"} "hello")}
;;TODO replace with rum equivelent
#_(reagent.core/unmount-component-at-node card)
(rum/mount app/Text card)
nil)
(defexample conj
(conj [] 1))
The expression (shadow.cljs.devtools.api/compile :docs {:verbose true}) returns the error:
[:docs] Compiling ...
-> build target: :browser stage: :configure
<- build target: :browser stage: :configure (0 ms)
-> Resolving Module: :main
The required namespace "cljsjs.rangy-core" is not available, it was required by "paren_soup/core.cljs".
However if i remove the dynadoc.core require, it does compile, but it doesn't properly eval the defexamples e.g the conj example above doesn't show the result [1]. Also my card doesn't render, but that might be another issue.
If anything to try pops out at you that would be great, hopefully, I can add a shadow example to the list.
A html file with header tags should be available, for example to include different stylesheets/CSS files for UI purposes
It would be pretty smooth if dynadoc could display the value computed by each line in a ->> or ->, not just the end result.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.