Skip to main content

Why API Documentation required on JS?



JavaScript Doc is the de facto standard for documenting JavaScript code. During my development period, I have worked with more than 50’s of JavaScript Libraries; after dealing with so many documentation, I found a lot of issues with JavaScript documentation. As lagging behind Good documentation, development time increases. A good documentation will decrease development time and it makes the developers life easy. It is very simple and easy to integrate with the system. Whatever the reason, not documenting an application is never a good thing, even if it is usually something of a chore.


This documentation will help you to understand the project and its flow, without looking into the actual code in very less time. All the entities described in document will also give link to the code of that particular entity. Let’s have a look for some of the commonly used annotations enlisted below:
Sr. No.
Annotation
Description
               1. 
@constructor
Marks the functions as the constructor.
         2.        
@function
To show a function or method, locally or globally.
         3.        
@param
To show the parameter of a function.
         4.        
@extends/@implements
To indicate the implementing interface or extending class of current class.
         5.        
@returns
Used to enlist return value from a function.
         6.        
@namespace
Shows that an object creating a namespace for its members.
         7.        
@type/@var
To show the member or it’s type.
         8.        
@memberOf
To show the parent of the member.

JSDoc is like an API documentation processor for the JavaScript. As a tool, JSDoc takes JavaScript code with special /** */ comments and produces HTML documentation for it. For example: Given the following code.



                     











The generated HTML looks as follows in a web browser:

                




Documentation is still scarce, but I hope this post help you how to run JavaScript Doc and how its syntax works, also very helpful in decreasing development time.

Comments

Popular posts from this blog

Building Contents of Watson Chatbots

In today’s world Chatbots are tremendously transforming the way we interact with software by providing a great business opportunity for almost every company. Chatbots are seen in almost all the websites and also in applications. The first question I ask to myself, what is Chatbot? Chatbots are known by different names some call it “conversational gents”, some “Chatter Robot”. Chatbots are basically a computer program that mimics written or spoken human speech in its natural format using Artificial Intelligence techniques such as Natural Language Processing (NLP) which is used for conversation purpose. In today’s era Chatbots are most commonly used in customer service space, acts as a human face of the brand for support operatives and customer satisfaction reps. We all know virtual assistants like Apple Siri or Amazon Alexa, are two most popular chatbots interacting via voice rather than text. Chatbots engages their customers in the right place, at the right time, with right

Neural Networks vs. Deep Learning

What’s the difference between deep learning and a regular neural network? The simple answer is that deep learning is larger in scale. Before we get into what that means, let’s talk about how a neural network functions. To make sense of observational data (like photos or audio), neural networks pass data through interconnected layers of nodes. When information passes through a layer, each node in that layer performs simple operations on the data and selectively passes the results to other nodes.  Each subsequent layer focuses on a higher-level feature than the last, until the network creates an output. In between the input layer and the output layer are hidden layers. And here’s where users typically differentiate between neural nets and deep learning: A basic neural network might have one or two hidden layers, while a deep learning network might have dozens or even hundreds. For example, a simple  neural network with a few hidden layers can solve a  common classification problem

Machine Learning The Easy Way

We are running in the most quality period of human race. when you open some article about machine learning, you see dozens of detailed descriptions. The idea behind writing this blog is to get the knowledge about Machine learning across the world. Through this blog, ML provides potential solutions in all different domains and more, and is set to be a pillar of our future civilization.. I am providing a flow level understanding about various machine learning Types along with description. These should be sufficient to get your hands dirty. So what exactly is “machine learning” Machine Learning (ML) is coming into its own, It is playing a key role in a wide range of critical applications, such as data mining, natural language processing, image recognition, and expert systems. Machine Learning is all around us. Apple, Amazon, Microsoft, Uber and many more companies are using machine learning. Generally there are four approaches in Machine Learning -: 1) Sup