1

"dart doc ." (or "dart doc") command is generation docs but only for everything in lib folder not sub folders. I have a src folder in lib which have other sub folders [lib > src > models > my_modal.dart] but after running command html is only generated for main.dart file (and a config.dart file in config folder [lib > config > config.dart])

here is my dart file

import 'package:photo_qc/src/screens/login_page.dart';

// common imports
import 'package:photo_qc/src/utils/common.dart';

/// App starts here at [main]
void main() async {
  /// Insures all widget bootstrapping
  WidgetsFlutterBinding.ensureInitialized();

  /// Creates HiveDB if not exists at [path]
  ///
  /// Links it with bloc architecture
  final Storage storage = await HydratedStorage.build(
    storageDirectory: await getApplicationDocumentsDirectory(),
  );

  /// Starts app
  ///
  /// Everything in [runZone] can access [HydratedBloc]
  HydratedBlocOverrides.runZoned(
    () => runApp(const LoginPage()),
    storage: storage,
  );
}

And here is my folder structure

  1. lib > main.dart
  2. lib > src > model > wall_model.dart
  3. lib > src > widgets > some.dart

My docs are as per Effective Dart guidelines and "dart analyse" (or "flutter analyse" ) commands giving 0 issues.

Here is a GitHub issue for the same.

Dartdoc-issue

Akshat Tamrakar
  • 2,193
  • 2
  • 13
  • 21

1 Answers1

1

Per this GitHub issue, that functionality is currently being added. Everything in the /lib/src folder is assumed to be private implementation and thus isn't documented. There is not yet an option to generate documentation for private implementations, but the above issue is tracking the process of adding that option.

TarHalda
  • 1,050
  • 1
  • 9
  • 27