Questions tagged [dartdoc]

DartDoc is the official "API documentation tool for Dart".

DartDoc is used "to generate HTML documentaton for your Dart package".

The dartdoc package can be found on Pub along with a GitHub repo for DartDoc

32 questions
1
vote
1 answer

Is there a way to document factory method parameters in Dart?

I'm developing a package for flutter and i am trying to add documentation for it, problem is i have a couple of factory methods and i want to document the individual parameters that go into them just like we do for constructors But i am out finding…
1
vote
1 answer

dart doc for libary, why is the main function not documented?

Hi i have build a blockchain and would like to document the api endpoints written in the main function now i have used dart doc to generate a documentation but it exludes the main function, does anyone know how to include…
Ketuf Wtf
  • 11
  • 4
1
vote
0 answers

dartdoc: How to split libraries list into subcategories (like in https://api.dart.dev/stable/2.16.2/index.html)

dartdoc: How to split libraries list into subcategories (like in https://api.dart.dev/stable/2.16.2/index.html) What I found so far: the description of subcategories wroten in file https://github.com/dart-lang/sdk/blob/main/sdk/lib/libraries.yaml…
1
vote
2 answers

How to not add every library inside Flutter project with Dartdoc

When I launch the command dartdoc --auto-include-dependencies, how can I do to not create documentation for every single library in the project? I use Melos in my project.
1
vote
1 answer

From given two lists, how to extract all the elements from one list that are not available in the other list in Dart?

I have two lists in Dart as below, final List availableIssueComponents = [ {'id': 1, 'componentName': 'Cash Acceptor'}, {'id': 2, 'componentName': 'Printer'}, {'id': 3, 'componentName': 'PIN Pad'}, {'id': 4, 'componentName': 'Key…
gfit21x
  • 141
  • 9
1
vote
0 answers

dart - What is the naming convention for templates and macro in comments

Dart has a dartdoc documentation syntax with {@template} and {@macro}. I was wondering if there was a naming convention for it. In the doc, they only give the {@template template_name} example which is in snake_case. For now, I'm naming my templates…
Valentin Vignal
  • 6,151
  • 2
  • 33
  • 73
1
vote
1 answer

How to refer to existing documentation

Here's an example of what I'm trying to accomplish. /// This is a doc string for this method. method1(){} @method1DocString ////method 2 doc string added to method1's here. method2(){} So method2's documentation would be: This is a doc string…
lenz
  • 2,193
  • 17
  • 31
0
votes
1 answer

How can I generate markdown docs with dartdoc 6.1.2

I used to generate markdown docs for my project with dartdoc 5.1.2 However,I find that there is no command or option to generate markdown docs when I update my dartdoc to version 6.1.2 I have tried these commands: dart doc --format md dart doc…
ttt
  • 1
0
votes
0 answers

How to make use of the Dart Documentation on the Official Dart Website

I am new to the Dart Programming language and I am having problem locating where I can learn the current Syntax of the Dart language as regards things like CONSTRUCTORS, CLASSES, FUNCTIONS, VARIABLES and so on. My visit to the following is not…
Philomental
  • 19
  • 1
  • 7
0
votes
3 answers

Display an image from the asset in the documentation

I'm writing documentation about a variable and I would like to include an image that is inside the project. For example: assets/ |- icons/ | |- my-image.svg lib/ |- my_file.dart I know it is possible to display an image from an URL, but what…
Valentin Vignal
  • 6,151
  • 2
  • 33
  • 73
0
votes
1 answer

dartdoc 4.1.0 failed: Invalid argument (uri): Unknown package: Instance of '_SimpleUri'

I get this error when running dartdoc for my dart package: Documenting my_library... Initialized dartdoc with 42 libraries in 12.1 seconds Generating docs for library my_library from package:my_library/my_library.dart... dartdoc 4.1.0…
JakesMD
  • 1,646
  • 2
  • 15
  • 35
0
votes
1 answer

The value I want is passed to the function by value rather than reference in Flutter. How to avoid this?

Inside my class I have the following class variables, Image? _pickedFrontImage; Image? _pickedBackImage; Then I have the below class method, void _setPickedImage(String path, Image? image) => setState( <------ Pay attention to the image…
CodeR_Ax20
  • 91
  • 1
  • 8
0
votes
0 answers

What is Dartdoc_options.yaml

Could someone explain me what is and how to create the file dartdoc_options.yaml ? Because I can't understand what kind of file is. And I tried to launch dartdoc, but seems that this file must stay in the project and without it, dartdoc dosen't…
0
votes
1 answer

Dartdoc -> Exclude method body

I'm trying to generate documentation using dartdoc. But when I run ... it includes method body e.g. codes inside a method. How can I ask it to use only method signature ( exclude method body ). Thanks.
0
votes
1 answer

How to remove "Make sure dartdoc successfully runs on your package's source files."

I published a Flutter package to https://pub.dev/ and find this message (shown in the screenshot). What do I have to do to solve this? This should be related to dartdoc, but I am not sure how much info I have to add. I also assume it is hard to make…
dmjy
  • 1,183
  • 3
  • 10
  • 26