diff --git a/packages/flutter_tools/templates/app/pubspec.yaml.tmpl b/packages/flutter_tools/templates/app/pubspec.yaml.tmpl index faa63962481..922184cb1a1 100644 --- a/packages/flutter_tools/templates/app/pubspec.yaml.tmpl +++ b/packages/flutter_tools/templates/app/pubspec.yaml.tmpl @@ -27,6 +27,11 @@ dependencies: {{#withPluginHook}} {{pluginProjectName}}: + # When depending on this package from a real application you should use: + # {{pluginProjectName}}: ^x.y.z + # See https://dart.dev/tools/pub/dependencies#version-constraints + # The example app is bundled with the plugin so we use a path dependency on + # the parent directory to use the current plugin's version. path: ../ {{/withPluginHook}}