SlideShare uma empresa Scribd logo
1 de 60
Baixar para ler offline
API Doc Smackdown

YUI Doc versus JS Doc Toolkit
Monday, September 14, 2009 - 2:25-3:25p
API Doc Smackdown

The Yahoo UI (YUI) Library is well known for its excellent documentation. One
of its secrets is YUI Doc, a Python application used at build time to generate
API documentation for JavaScript code.

But is YUI Doc really better than JS Doc Toolkit? -- an elder application, written
in JavaScript, that also generates API documentation. When should you
choose one over the other? Which is the better choice for your project?

In this session you will learn:

* How API generators work, and how documentation helps;
* When to use YUI Doc and when to use JS Doc Toolkit;
* More about alternatives to comment-based documentation.
http://www.slideshare.net/ted.husted
Old School

push RA ; push register A to retain the subtotal
pop RB ; pop register B to recall the total
Source Code Stakeholders

 Solution Architects
 Product Managers
 QA Engineers
 Maintenance Engineers
 Customers
Why not doc?

 Embedded comments clutter up the code
 External document is difficult to synchronize
http://java.sun.com/j2se/javadoc/writingdoccomments/
http://java.sun.com/j2se/javadoc/writingdoccomments/
http://www.j2ee.me/javase/7/docs/api/index.html?overview-summary.html
Some IDEs with API Doc Support

 Eclipse              Visual Studio
 Aptana (ScriptDoc)   Resharper for VS
                      IDEA IntelliJ




Any others?
http://ndoc.sourceforge.net/
http://sandcastle.codeplex.com/
http://www.codeplex.com/DocProject
http://en.wikipedia.org/wiki/Comparison_of_documentation_generators
http://www.phpdoc.org/
http://rdoc.rubyforge.org/
http://www.birt-exchange.org/documentation/JavaComponents10/JSAPI-JSdoc/
http://developer.yahoo.com/yui/docs/
http://developer.yahoo.com/yui/yuidoc/
http://developer.yahoo.com/yui/yuidoc/
http://developer.yahoo.com/yui/yuidoc/
http://developer.yahoo.com/yui/yuidoc/
http://developer.yahoo.com/yui/yuidoc/
http://developer.yahoo.com/yui/yuidoc/
YUI Doc Pros and Cons

Pros                       Cons
   Concise set of tags       YUI specific idioms
   Used by YUI library       Overshadowed by YUI
   supported by YUI Team     Small community
http://developer.yahoo.com/yui/yuidoc/
http://code.google.com/p/jsdoc-toolkit/
http://code.google.com/p/jsdoc-toolkit/w/list
http://code.google.com/p/jsdoc-toolkit/w/list
http://code.google.com/p/jsdoc-toolkit/
http://code.google.com/p/jsdoc-toolkit/
http://docs.jproton.com.br/
http://lib.metatype.jp/madtemplate/
http://projects.vinces.ca/jsdocs/
http://code.google.com/p/jsdoc-toolkit/wiki/Templates
http://code.google.com/p/jsdoc-toolkit/wiki/Templates
http://code.google.com/p/jsdoc-toolkit/wiki/Templates
http://developer.yahoo.com/yui/yuidoc/#custom
D:optYahooyuidoc_1.0.0b1yuidoctemplatemain.tmpl
JsDoc Toolkit Pros and Cons

Pros                       Cons

  Deep and broad tab set     Sketchy documentation
  Used by many projects      Lacks "anchor" project
  Well supported             Sole developer
Time for a Test Drive ...
Installing YUI Doc
 Python 2.5
    C:Python25

 SetupTools
     $python_homeScriptseasy_install* (executables)
 .> easy_install pygments
 .> easy_install simplejson
 .> easy_install cheetah

 YUI Doc Distribution
   bin/example.bat
   bin/example.sh
http://python.org/download/releases/2.5.4/
python-2.5.4.msi
http://pypi.python.org/pypi/setuptools
setuptools-0.6c9.win32-py2.5.exe
1.   easy_install pygments
  2.   easy_install Cheetah
  3.   easy_install simplejson




C:Python25Scriptseasy_install
c:optyahooyuidoc_1.0.0b1yuidocbinexample.bat
c:optyahooyuidoc_1.0.0b1yuidocbinexample.bat
Installing JsDoc Toolkit

   Java 1.5 or 1.6
   JsDoc Distribution
      app
      conf
      java
      templates
   > java -jar jsrun.jar apprun.js
       -a -t=templatesjsdoc
       -r app/frame.js appframe app/handler
   out/jsdoc
        index.html
        files.html
        symbols

http://code.google.com/p/jsdoc-toolkit/
file:///D:/opt/GoogleCode/jsdoc_toolkit-2.3.2/jsdoc-toolkit/out/jsdoc/index.
YUI Doc vs JsDoc Toolkit

YUI Doc Pros                YUI Doc Cons
  Concise set of tabs         YUI specific idioms
  Used by YUI library         Overshadowed by YUI
  Supported by YUI Team       Small community

Js Doc Pros                 Js Doc Cons

   Deep and broad tag set     Sketchy documentation
   Used by many projects      Lacks "anchor" project
   Well supported             Sole developer
http://dojodocs.uxebu.com/
http://scriptdoc.org/
Style Guide
   Use <code> style for keywords and name
   Use in-line links economically
   Omit parentheses for the general form of methods and
   constructors
   Okay to use phrases instead of complete sentences, in the
   interests of brevity.
   Use 3rd person (descriptive) not 2nd person (prescriptive)
   Method descriptions begin with a verb phrase.
   Class/interface/field descriptions can omit the subject and
   simply state the object.
   Use "this" instead of "the" when referring to an object
   created from the current class.
    Use "this" instead of "the" when referring to an object
   created from the current class.
   Avoid Latin.
http://code.google.com/p/jsdoc-toolkit/
Please complete
 an evaluation.
Questions?




http://www.slideshare.net/ted.husted

Mais conteúdo relacionado

Semelhante a API Doc Smackdown

Testing in Android: automatici, di integrazione, TDD e scenari avanzati
Testing in Android: automatici, di integrazione, TDD e scenari avanzatiTesting in Android: automatici, di integrazione, TDD e scenari avanzati
Testing in Android: automatici, di integrazione, TDD e scenari avanzati
Alfredo Morresi
 
Creating Custom Dojo Widgets Using WTP
Creating Custom Dojo Widgets Using WTPCreating Custom Dojo Widgets Using WTP
Creating Custom Dojo Widgets Using WTP
nsandonato
 
JavaScript Tools Overview
JavaScript Tools OverviewJavaScript Tools Overview
JavaScript Tools Overview
Scott Povlot
 
Novice Programmers Workshop
Novice Programmers WorkshopNovice Programmers Workshop
Novice Programmers Workshop
Alec Clews
 

Semelhante a API Doc Smackdown (20)

Testing in Android: automatici, di integrazione, TDD e scenari avanzati
Testing in Android: automatici, di integrazione, TDD e scenari avanzatiTesting in Android: automatici, di integrazione, TDD e scenari avanzati
Testing in Android: automatici, di integrazione, TDD e scenari avanzati
 
Understanding Technologies - Presentation for College Students
Understanding Technologies - Presentation for College StudentsUnderstanding Technologies - Presentation for College Students
Understanding Technologies - Presentation for College Students
 
Front-end development introduction (JavaScript). Part 2
Front-end development introduction (JavaScript). Part 2Front-end development introduction (JavaScript). Part 2
Front-end development introduction (JavaScript). Part 2
 
Introduction to Google App Engine with Python
Introduction to Google App Engine with PythonIntroduction to Google App Engine with Python
Introduction to Google App Engine with Python
 
Survival Strategies for API Documentation: Presentation to Southwestern Ontar...
Survival Strategies for API Documentation: Presentation to Southwestern Ontar...Survival Strategies for API Documentation: Presentation to Southwestern Ontar...
Survival Strategies for API Documentation: Presentation to Southwestern Ontar...
 
Scripting in OpenOffice.org
Scripting in OpenOffice.orgScripting in OpenOffice.org
Scripting in OpenOffice.org
 
API Documentation Workshop tcworld India 2015
API Documentation Workshop tcworld India 2015API Documentation Workshop tcworld India 2015
API Documentation Workshop tcworld India 2015
 
Creating Custom Dojo Widgets Using WTP
Creating Custom Dojo Widgets Using WTPCreating Custom Dojo Widgets Using WTP
Creating Custom Dojo Widgets Using WTP
 
JavaScript Presentation Frameworks and Libraries
JavaScript Presentation Frameworks and LibrariesJavaScript Presentation Frameworks and Libraries
JavaScript Presentation Frameworks and Libraries
 
Boquet manager
Boquet managerBoquet manager
Boquet manager
 
opps.pptx
opps.pptxopps.pptx
opps.pptx
 
Web Development in Django
Web Development in DjangoWeb Development in Django
Web Development in Django
 
Building Cross-Platform Mobile Apps
Building Cross-Platform Mobile AppsBuilding Cross-Platform Mobile Apps
Building Cross-Platform Mobile Apps
 
.NET Recommended Resources
.NET Recommended Resources.NET Recommended Resources
.NET Recommended Resources
 
Le Tour de xUnit
Le Tour de xUnitLe Tour de xUnit
Le Tour de xUnit
 
Building Rich Applications with Appcelerator
Building Rich Applications with AppceleratorBuilding Rich Applications with Appcelerator
Building Rich Applications with Appcelerator
 
JavaScript Tools Overview
JavaScript Tools OverviewJavaScript Tools Overview
JavaScript Tools Overview
 
Novice Programmers Workshop
Novice Programmers WorkshopNovice Programmers Workshop
Novice Programmers Workshop
 
The JavaScript Revue: Patterns & Frameworks
The JavaScript Revue: Patterns & FrameworksThe JavaScript Revue: Patterns & Frameworks
The JavaScript Revue: Patterns & Frameworks
 
Spring roo for entrepreneurs
Spring roo for entrepreneursSpring roo for entrepreneurs
Spring roo for entrepreneurs
 

Mais de Ted Husted

Open Source Secret Sauce - Lugor Sep 2011
Open Source Secret Sauce - Lugor Sep 2011Open Source Secret Sauce - Lugor Sep 2011
Open Source Secret Sauce - Lugor Sep 2011
Ted Husted
 
Open source secret_sauce_apache_con_2010
Open source secret_sauce_apache_con_2010Open source secret_sauce_apache_con_2010
Open source secret_sauce_apache_con_2010
Ted Husted
 
Drupal kickstart-workshop
Drupal kickstart-workshopDrupal kickstart-workshop
Drupal kickstart-workshop
Ted Husted
 

Mais de Ted Husted (19)

Ship It!
Ship It!Ship It!
Ship It!
 
.NET @ apache.org
 .NET @ apache.org .NET @ apache.org
.NET @ apache.org
 
The secret life_of_open_source
The secret life_of_open_sourceThe secret life_of_open_source
The secret life_of_open_source
 
Open Source Secret Sauce - Lugor Sep 2011
Open Source Secret Sauce - Lugor Sep 2011Open Source Secret Sauce - Lugor Sep 2011
Open Source Secret Sauce - Lugor Sep 2011
 
NU FaceBook 101 JCC 2010
NU  FaceBook 101 JCC 2010NU  FaceBook 101 JCC 2010
NU FaceBook 101 JCC 2010
 
Developing java Web Applications Using Google Apps RJUG 2011
Developing java Web Applications Using Google Apps RJUG 2011Developing java Web Applications Using Google Apps RJUG 2011
Developing java Web Applications Using Google Apps RJUG 2011
 
Open source secret_sauce_apache_con_2010
Open source secret_sauce_apache_con_2010Open source secret_sauce_apache_con_2010
Open source secret_sauce_apache_con_2010
 
Drupal kickstart-workshop
Drupal kickstart-workshopDrupal kickstart-workshop
Drupal kickstart-workshop
 
Open source-secret-sauce-rit-2010
Open source-secret-sauce-rit-2010Open source-secret-sauce-rit-2010
Open source-secret-sauce-rit-2010
 
Agile Analysis with Use Cases: Balancing Utility with Simplicity
Agile Analysis with Use Cases: Balancing Utility with SimplicityAgile Analysis with Use Cases: Balancing Utility with Simplicity
Agile Analysis with Use Cases: Balancing Utility with Simplicity
 
Testing Web Application Security
Testing Web Application SecurityTesting Web Application Security
Testing Web Application Security
 
Testing The Testers
Testing The TestersTesting The Testers
Testing The Testers
 
Testing Ajax Applications
Testing Ajax ApplicationsTesting Ajax Applications
Testing Ajax Applications
 
Testing Ajax Web Applications
Testing Ajax Web ApplicationsTesting Ajax Web Applications
Testing Ajax Web Applications
 
Testing Tools
Testing ToolsTesting Tools
Testing Tools
 
Coding Ajax
Coding AjaxCoding Ajax
Coding Ajax
 
Coding Ajax
Coding AjaxCoding Ajax
Coding Ajax
 
Retrofitting
RetrofittingRetrofitting
Retrofitting
 
Open Source Secret Sauce
Open Source Secret SauceOpen Source Secret Sauce
Open Source Secret Sauce
 

Último

Structuring Teams and Portfolios for Success
Structuring Teams and Portfolios for SuccessStructuring Teams and Portfolios for Success
Structuring Teams and Portfolios for Success
UXDXConf
 
Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...
Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...
Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...
panagenda
 

Último (20)

Enterprise Knowledge Graphs - Data Summit 2024
Enterprise Knowledge Graphs - Data Summit 2024Enterprise Knowledge Graphs - Data Summit 2024
Enterprise Knowledge Graphs - Data Summit 2024
 
IESVE for Early Stage Design and Planning
IESVE for Early Stage Design and PlanningIESVE for Early Stage Design and Planning
IESVE for Early Stage Design and Planning
 
Choosing the Right FDO Deployment Model for Your Application _ Geoffrey at In...
Choosing the Right FDO Deployment Model for Your Application _ Geoffrey at In...Choosing the Right FDO Deployment Model for Your Application _ Geoffrey at In...
Choosing the Right FDO Deployment Model for Your Application _ Geoffrey at In...
 
Intro in Product Management - Коротко про професію продакт менеджера
Intro in Product Management - Коротко про професію продакт менеджераIntro in Product Management - Коротко про професію продакт менеджера
Intro in Product Management - Коротко про професію продакт менеджера
 
WebAssembly is Key to Better LLM Performance
WebAssembly is Key to Better LLM PerformanceWebAssembly is Key to Better LLM Performance
WebAssembly is Key to Better LLM Performance
 
AI mind or machine power point presentation
AI mind or machine power point presentationAI mind or machine power point presentation
AI mind or machine power point presentation
 
Working together SRE & Platform Engineering
Working together SRE & Platform EngineeringWorking together SRE & Platform Engineering
Working together SRE & Platform Engineering
 
Structuring Teams and Portfolios for Success
Structuring Teams and Portfolios for SuccessStructuring Teams and Portfolios for Success
Structuring Teams and Portfolios for Success
 
Powerful Start- the Key to Project Success, Barbara Laskowska
Powerful Start- the Key to Project Success, Barbara LaskowskaPowerful Start- the Key to Project Success, Barbara Laskowska
Powerful Start- the Key to Project Success, Barbara Laskowska
 
Where to Learn More About FDO _ Richard at FIDO Alliance.pdf
Where to Learn More About FDO _ Richard at FIDO Alliance.pdfWhere to Learn More About FDO _ Richard at FIDO Alliance.pdf
Where to Learn More About FDO _ Richard at FIDO Alliance.pdf
 
Google I/O Extended 2024 Warsaw
Google I/O Extended 2024 WarsawGoogle I/O Extended 2024 Warsaw
Google I/O Extended 2024 Warsaw
 
Your enemies use GenAI too - staying ahead of fraud with Neo4j
Your enemies use GenAI too - staying ahead of fraud with Neo4jYour enemies use GenAI too - staying ahead of fraud with Neo4j
Your enemies use GenAI too - staying ahead of fraud with Neo4j
 
Syngulon - Selection technology May 2024.pdf
Syngulon - Selection technology May 2024.pdfSyngulon - Selection technology May 2024.pdf
Syngulon - Selection technology May 2024.pdf
 
Simplified FDO Manufacturing Flow with TPMs _ Liam at Infineon.pdf
Simplified FDO Manufacturing Flow with TPMs _ Liam at Infineon.pdfSimplified FDO Manufacturing Flow with TPMs _ Liam at Infineon.pdf
Simplified FDO Manufacturing Flow with TPMs _ Liam at Infineon.pdf
 
TEST BANK For, Information Technology Project Management 9th Edition Kathy Sc...
TEST BANK For, Information Technology Project Management 9th Edition Kathy Sc...TEST BANK For, Information Technology Project Management 9th Edition Kathy Sc...
TEST BANK For, Information Technology Project Management 9th Edition Kathy Sc...
 
What's New in Teams Calling, Meetings and Devices April 2024
What's New in Teams Calling, Meetings and Devices April 2024What's New in Teams Calling, Meetings and Devices April 2024
What's New in Teams Calling, Meetings and Devices April 2024
 
Extensible Python: Robustness through Addition - PyCon 2024
Extensible Python: Robustness through Addition - PyCon 2024Extensible Python: Robustness through Addition - PyCon 2024
Extensible Python: Robustness through Addition - PyCon 2024
 
AI presentation and introduction - Retrieval Augmented Generation RAG 101
AI presentation and introduction - Retrieval Augmented Generation RAG 101AI presentation and introduction - Retrieval Augmented Generation RAG 101
AI presentation and introduction - Retrieval Augmented Generation RAG 101
 
Long journey of Ruby Standard library at RubyKaigi 2024
Long journey of Ruby Standard library at RubyKaigi 2024Long journey of Ruby Standard library at RubyKaigi 2024
Long journey of Ruby Standard library at RubyKaigi 2024
 
Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...
Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...
Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...
 

API Doc Smackdown