Tutorial by Examples

Everything to the right of // in the same line is commented. int i = 0; // Commented out text
Everything between /* and */ is commented. void main() { for (int i = 0; i < 5; i++) { /* This is commented, and will not affect code */ print('hello ${i + 1}'); } }
Using a doc comment instead of a regular comment enables dartdoc to find it and generate documentation for it. /// The number of characters in this chunk when unsplit. int get length => ... You are allowed to use most markdown formatting in your doc comments and dartdoc will process it accor...

Page 1 of 1