croquiscom / crojsdoc Goto Github PK
View Code? Open in Web Editor NEWA documentation generator for JavaScript and CoffeeScript
Home Page: http://croquiscom.github.io/crojsdoc/
A documentation generator for JavaScript and CoffeeScript
Home Page: http://croquiscom.github.io/crojsdoc/
For example,
class User extends cormo.Model
##
# User email
@column 'email', String
instead of
class User extends cormo.Model
##
# User email
# @property 'email'
# @type String
@column 'email', String
When using @extend
keyword with class that isn't declared in my project, but it's native node.js class I get red text on gray background like it's error. Code example:
###
# @module DownloadHandler
###
EventEmitter = require('events').EventEmitter
###
# Class to handle file downloads
# @namespace Download
# @class DownloadHandler
# @extends EventEmitter
###
class DownloadHandler extends EventEmitter
###
# Constructor
###
constructor: ->
EventEmitter.call this
module.exports = DownloadHandler
I just played arround with crojs and it looks very promising to me!
But ;), have a couple of sub-folder (.build, .git etc.) which i would like to exclude from the docs.
I tried to use wildcards (foldername/*.coffee) but they don't seem to work. Have you considered to use wildcards as sources?
jörn
The docs say there is an example
tag available. However my compiler keeps feeding me
Unknown tag : example in C:/_dev/feathers_mongodb/lib/mongodb.coffee
Here is my usage
# @example
# # remove aggregate functionality for `todoService`
# mongodb = require 'oscar-mongodb'
# mongodb.connect ->
# todoService = mongodb 'todo'
# delete todoService.options.pipeline
The examples are parsed and included, however, I cannot give them a title, nor is the code indented as in the documentation (I use two spaces). My version is [email protected]
and I am on windows 7.
Installing crojsdoc as global:
Running: crojsdoc example.js generates doc folder with items, but doesn't parse file. Generated document is emty.
How can we debug parsing of document?
When I declare a class to be abstract, it doesn't show that it's abstract in the docs. I see in the code that it checks for abstract on properties, but couldn't find where the template renders abstract. Am I missing something?
Is it possible to create class documentation for code that doesn't use @class
syntax? Eg.
###
# Class responsible for managing user's config
# @class Config
# @namespace Application
###
App.Config = Em.Object.extend
keys: [
App.ConfigKey.create
Name: 'downloadPath'
DefaultValue: ''
App.ConfigKey.create
Name: 'language'
DefaultValue: 'en'
App.ConfigKey.create
Name: 'platform'
DefaultValue: 'windows'
]
columns: [
new Column 'Id', 'INTEGER', false, true, true
new Column 'Key', 'TEXT', true, false, false, true
new Column 'Value', 'TEXT'
]
###
# Method to get complete SQL code to create Config table.
# @return {String} SQL code for Config table.
# @memberof Config
###
getCreateTableSQL: ->
columns = @get 'columns'
len = columns.length
columnsSQL = ''
for column, i in columns
columnsSQL += if len - 1 is i then column.getSQL() else column.getSQL() + ', '
'CREATE TABLE IF NOT EXISTS `config` (' + columnsSQL + ')'
This code displays only Config class in Classes, without any members.
If I have a folder src
I would like crojsdoc to parse all .coffee
files in its subfolders.
With .gitignores
for example, I would write src/**/*.coffee
, but there seems to be no pattern support in crojsdoc right now.
I have not found a way to write a description for a return value in multiple lines. I'm using coffeescript.
###
# This function does something.
# This is also part of the description which is no problem.
#
# @return {String} This is a very long description that spans
# multiple lines for better readability.
###
It results in the description being truncated after ... spans
.
This:
###
# @param {Array<Object>} [this.options.initialModels=[]] Initial models.
###
renders as:
initialModels=[
instead of:
initialModels=[] [optional]
Param with @
isn't detected and documented. It displays: Parameters: (None)
. Tried:
###
# Youtube video class
###
class YtVideo extends EventEmitter
###
# Constructor
# @param {String} Url YouTube link
###
constructor: (@Url) ->
EventEmitter.call this
And:
###
# Youtube video class
###
class YtVideo extends EventEmitter
###
# Constructor
# @param {String} @Url YouTube link
###
constructor: (@Url) ->
EventEmitter.call this
How to properly document this parameter?
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.