Showing
13 changed files
with
380 additions
and
16 deletions
pdf/analysis_options.yaml
0 → 100644
1 | +# Specify analysis options. | ||
2 | +# | ||
3 | +# Until there are meta linter rules, each desired lint must be explicitly enabled. | ||
4 | +# See: https://github.com/dart-lang/linter/issues/288 | ||
5 | +# | ||
6 | +# For a list of lints, see: http://dart-lang.github.io/linter/lints/ | ||
7 | +# See the configuration guide for more | ||
8 | +# https://github.com/dart-lang/sdk/tree/master/pkg/analyzer#configuring-the-analyzer | ||
9 | +# | ||
10 | +# There are other similar analysis options files in the flutter repos, | ||
11 | +# which should be kept in sync with this file: | ||
12 | +# | ||
13 | +# - analysis_options.yaml (this file) | ||
14 | +# - packages/flutter/lib/analysis_options_user.yaml | ||
15 | +# - https://github.com/flutter/plugins/blob/master/analysis_options.yaml | ||
16 | +# - https://github.com/flutter/engine/blob/master/analysis_options.yaml | ||
17 | +# | ||
18 | +# This file contains the analysis options used by Flutter tools, such as IntelliJ, | ||
19 | +# Android Studio, and the `flutter analyze` command. | ||
20 | + | ||
21 | +analyzer: | ||
22 | + strong-mode: | ||
23 | + implicit-dynamic: false | ||
24 | + errors: | ||
25 | + # treat missing required parameters as a warning (not a hint) | ||
26 | + missing_required_param: warning | ||
27 | + # treat missing returns as a warning (not a hint) | ||
28 | + missing_return: warning | ||
29 | + # allow having TODOs in the code | ||
30 | + todo: ignore | ||
31 | + # Ignore analyzer hints for updating pubspecs when using Future or | ||
32 | + # Stream and not importing dart:async | ||
33 | + # Please see https://github.com/flutter/flutter/pull/24528 for details. | ||
34 | + sdk_version_async_exported_from_core: ignore | ||
35 | + exclude: | ||
36 | + - 'bin/cache/**' | ||
37 | + # the following two are relative to the stocks example and the flutter package respectively | ||
38 | + # see https://github.com/dart-lang/sdk/issues/28463 | ||
39 | + - 'lib/i18n/stock_messages_*.dart' | ||
40 | + - 'lib/src/http/**' | ||
41 | + | ||
42 | +linter: | ||
43 | + rules: | ||
44 | + # these rules are documented on and in the same order as | ||
45 | + # the Dart Lint rules page to make maintenance easier | ||
46 | + # https://github.com/dart-lang/linter/blob/master/example/all.yaml | ||
47 | + - always_declare_return_types | ||
48 | + - always_put_control_body_on_new_line | ||
49 | + # - always_put_required_named_parameters_first # we prefer having parameters in the same order as fields https://github.com/flutter/flutter/issues/10219 | ||
50 | + - always_require_non_null_named_parameters | ||
51 | + - always_specify_types | ||
52 | + - annotate_overrides | ||
53 | + # - avoid_annotating_with_dynamic # conflicts with always_specify_types | ||
54 | + - avoid_as | ||
55 | + # - avoid_bool_literals_in_conditional_expressions # not yet tested | ||
56 | + # - avoid_catches_without_on_clauses # we do this commonly | ||
57 | + # - avoid_catching_errors # we do this commonly | ||
58 | + - avoid_classes_with_only_static_members | ||
59 | + # - avoid_double_and_int_checks # only useful when targeting JS runtime | ||
60 | + - avoid_empty_else | ||
61 | + - avoid_field_initializers_in_const_classes | ||
62 | + - avoid_function_literals_in_foreach_calls | ||
63 | + # - avoid_implementing_value_types # not yet tested | ||
64 | + - avoid_init_to_null | ||
65 | + # - avoid_js_rounded_ints # only useful when targeting JS runtime | ||
66 | + - avoid_null_checks_in_equality_operators | ||
67 | + # - avoid_positional_boolean_parameters # not yet tested | ||
68 | + # - avoid_private_typedef_functions # we prefer having typedef (discussion in https://github.com/flutter/flutter/pull/16356) | ||
69 | + - avoid_relative_lib_imports | ||
70 | + - avoid_renaming_method_parameters | ||
71 | + - avoid_return_types_on_setters | ||
72 | + # - avoid_returning_null # there are plenty of valid reasons to return null | ||
73 | + # - avoid_returning_null_for_future # not yet tested | ||
74 | + - avoid_returning_null_for_void | ||
75 | + # - avoid_returning_this # there are plenty of valid reasons to return this | ||
76 | + # - avoid_setters_without_getters # not yet tested | ||
77 | + # - avoid_shadowing_type_parameters # not yet tested | ||
78 | + # - avoid_single_cascade_in_expression_statements # not yet tested | ||
79 | + - avoid_slow_async_io | ||
80 | + - avoid_types_as_parameter_names | ||
81 | + # - avoid_types_on_closure_parameters # conflicts with always_specify_types | ||
82 | + - avoid_unused_constructor_parameters | ||
83 | + - avoid_void_async | ||
84 | + - await_only_futures | ||
85 | + - camel_case_types | ||
86 | + - cancel_subscriptions | ||
87 | + # - cascade_invocations # not yet tested | ||
88 | + # - close_sinks # not reliable enough | ||
89 | + # - comment_references # blocked on https://github.com/flutter/flutter/issues/20765 | ||
90 | + # - constant_identifier_names # needs an opt-out https://github.com/dart-lang/linter/issues/204 | ||
91 | + - control_flow_in_finally | ||
92 | + # - curly_braces_in_flow_control_structures # not yet tested | ||
93 | + - directives_ordering | ||
94 | + - empty_catches | ||
95 | + - empty_constructor_bodies | ||
96 | + - empty_statements | ||
97 | + # - file_names # not yet tested | ||
98 | + - flutter_style_todos | ||
99 | + - hash_and_equals | ||
100 | + - implementation_imports | ||
101 | + # - invariant_booleans # too many false positives: https://github.com/dart-lang/linter/issues/811 | ||
102 | + - iterable_contains_unrelated_type | ||
103 | + # - join_return_with_assignment # not yet tested | ||
104 | + - library_names | ||
105 | + - library_prefixes | ||
106 | + # - lines_longer_than_80_chars # not yet tested | ||
107 | + - list_remove_unrelated_type | ||
108 | + # - literal_only_boolean_expressions # too many false positives: https://github.com/dart-lang/sdk/issues/34181 | ||
109 | + - no_adjacent_strings_in_list | ||
110 | + - no_duplicate_case_values | ||
111 | + - non_constant_identifier_names | ||
112 | + # - null_closures # not yet tested | ||
113 | + # - omit_local_variable_types # opposite of always_specify_types | ||
114 | + # - one_member_abstracts # too many false positives | ||
115 | + # - only_throw_errors # https://github.com/flutter/flutter/issues/5792 | ||
116 | + - overridden_fields | ||
117 | + - package_api_docs | ||
118 | + - package_names | ||
119 | + - package_prefixed_library_names | ||
120 | + # - parameter_assignments # we do this commonly | ||
121 | + - prefer_adjacent_string_concatenation | ||
122 | + - prefer_asserts_in_initializer_lists | ||
123 | + - prefer_collection_literals | ||
124 | + - prefer_conditional_assignment | ||
125 | + - prefer_const_constructors | ||
126 | + - prefer_const_constructors_in_immutables | ||
127 | + - prefer_const_declarations | ||
128 | + - prefer_const_literals_to_create_immutables | ||
129 | + # - prefer_constructors_over_static_methods # not yet tested | ||
130 | + - prefer_contains | ||
131 | + - prefer_equal_for_default_values | ||
132 | + # - prefer_expression_function_bodies # conflicts with https://github.com/flutter/flutter/wiki/Style-guide-for-Flutter-repo#consider-using--for-short-functions-and-methods | ||
133 | + - prefer_final_fields | ||
134 | + - prefer_final_locals | ||
135 | + - prefer_foreach | ||
136 | + # - prefer_function_declarations_over_variables # not yet tested | ||
137 | + - prefer_generic_function_type_aliases | ||
138 | + - prefer_initializing_formals | ||
139 | + # - prefer_int_literals # not yet tested | ||
140 | + # - prefer_interpolation_to_compose_strings # not yet tested | ||
141 | + - prefer_is_empty | ||
142 | + - prefer_is_not_empty | ||
143 | + - prefer_iterable_whereType | ||
144 | + # - prefer_mixin # https://github.com/dart-lang/language/issues/32 | ||
145 | + - prefer_single_quotes | ||
146 | + - prefer_typing_uninitialized_variables | ||
147 | + - prefer_void_to_null | ||
148 | + # - public_member_api_docs # enabled on a case-by-case basis; see e.g. packages/analysis_options.yaml | ||
149 | + - recursive_getters | ||
150 | + - slash_for_doc_comments | ||
151 | + - sort_constructors_first | ||
152 | + - sort_pub_dependencies | ||
153 | + - sort_unnamed_constructors_first | ||
154 | + - super_goes_last | ||
155 | + - test_types_in_equals | ||
156 | + - throw_in_finally | ||
157 | + # - type_annotate_public_apis # subset of always_specify_types | ||
158 | + - type_init_formals | ||
159 | + # - unawaited_futures # too many false positives | ||
160 | + # - unnecessary_await_in_return # not yet tested | ||
161 | + - unnecessary_brace_in_string_interps | ||
162 | + - unnecessary_const | ||
163 | + - unnecessary_getters_setters | ||
164 | + # - unnecessary_lambdas # has false positives: https://github.com/dart-lang/linter/issues/498 | ||
165 | + - unnecessary_new | ||
166 | + - unnecessary_null_aware_assignments | ||
167 | + - unnecessary_null_in_if_null_operators | ||
168 | + - unnecessary_overrides | ||
169 | + - unnecessary_parenthesis | ||
170 | + - unnecessary_statements | ||
171 | + - unnecessary_this | ||
172 | + - unrelated_type_equality_checks | ||
173 | + # - use_function_type_syntax_for_parameters # not yet tested | ||
174 | + - use_rethrow_when_possible | ||
175 | + # - use_setters_to_change_properties # not yet tested | ||
176 | + # - use_string_buffers # has false positives: https://github.com/dart-lang/sdk/issues/34182 | ||
177 | + # - use_to_and_as_if_applicable # has false positives, so we prefer to catch this by code-review | ||
178 | + - valid_regexps | ||
179 | + # - void_checks # not yet tested |
@@ -42,7 +42,7 @@ class PdfCatalog extends PdfObject { | @@ -42,7 +42,7 @@ class PdfCatalog extends PdfObject { | ||
42 | params["/Pages"] = pdfPageList.ref(); | 42 | params["/Pages"] = pdfPageList.ref(); |
43 | 43 | ||
44 | // the Outlines object | 44 | // the Outlines object |
45 | - if (outlines != null && outlines.outlines.length > 0) { | 45 | + if (outlines != null && outlines.outlines.isNotEmpty) { |
46 | params["/Outlines"] = outlines.ref(); | 46 | params["/Outlines"] = outlines.ref(); |
47 | } | 47 | } |
48 | 48 |
@@ -56,7 +56,7 @@ class PdfFont extends PdfObject { | @@ -56,7 +56,7 @@ class PdfFont extends PdfObject { | ||
56 | PdfRect stringBounds(String s) { | 56 | PdfRect stringBounds(String s) { |
57 | var chars = latin1.encode(s); | 57 | var chars = latin1.encode(s); |
58 | 58 | ||
59 | - if (chars.length == 0) return const PdfRect(0.0, 0.0, 0.0, 0.0); | 59 | + if (chars.isEmpty) return const PdfRect(0.0, 0.0, 0.0, 0.0); |
60 | 60 | ||
61 | var n = 0; | 61 | var n = 0; |
62 | var c = chars[n]; | 62 | var c = chars[n]; |
@@ -44,16 +44,16 @@ class PdfFormXObject extends PdfXObject { | @@ -44,16 +44,16 @@ class PdfFormXObject extends PdfXObject { | ||
44 | final resources = Map<String, PdfStream>(); | 44 | final resources = Map<String, PdfStream>(); |
45 | 45 | ||
46 | // fonts | 46 | // fonts |
47 | - if (fonts.length > 0) { | 47 | + if (fonts.isNotEmpty) { |
48 | resources["/Font"] = PdfStream()..putObjectDictionary(fonts); | 48 | resources["/Font"] = PdfStream()..putObjectDictionary(fonts); |
49 | } | 49 | } |
50 | 50 | ||
51 | // Now the XObjects | 51 | // Now the XObjects |
52 | - if (xobjects.length > 0) { | 52 | + if (xobjects.isNotEmpty) { |
53 | resources["/XObject"] = PdfStream()..putObjectDictionary(xobjects); | 53 | resources["/XObject"] = PdfStream()..putObjectDictionary(xobjects); |
54 | } | 54 | } |
55 | 55 | ||
56 | - if (resources.length > 0) { | 56 | + if (resources.isNotEmpty) { |
57 | params["/Resources"] = PdfStream.dictionary(resources); | 57 | params["/Resources"] = PdfStream.dictionary(resources); |
58 | } | 58 | } |
59 | } | 59 | } |
@@ -32,7 +32,7 @@ class PdfGraphics { | @@ -32,7 +32,7 @@ class PdfGraphics { | ||
32 | PdfGraphics(this.page, this.buf); | 32 | PdfGraphics(this.page, this.buf); |
33 | 33 | ||
34 | PdfFont get defaultFont { | 34 | PdfFont get defaultFont { |
35 | - if (page.pdfDocument.fonts.length == 0) { | 35 | + if (page.pdfDocument.fonts.isEmpty) { |
36 | PdfFont.helvetica(page.pdfDocument); | 36 | PdfFont.helvetica(page.pdfDocument); |
37 | } | 37 | } |
38 | 38 | ||
@@ -460,7 +460,7 @@ class PdfGraphics { | @@ -460,7 +460,7 @@ class PdfGraphics { | ||
460 | case 'S': // smooth cubic bézier, absolute | 460 | case 'S': // smooth cubic bézier, absolute |
461 | while (points.length >= 4) { | 461 | while (points.length >= 4) { |
462 | PdfPoint c1; | 462 | PdfPoint c1; |
463 | - if ('cCsS'.indexOf(lastAction) >= 0) { | 463 | + if ('cCsS'.contains(lastAction)) { |
464 | c1 = PdfPoint(lastPoint.x + (lastPoint.x - lastControl.x), | 464 | c1 = PdfPoint(lastPoint.x + (lastPoint.x - lastControl.x), |
465 | lastPoint.y + (lastPoint.y - lastControl.y)); | 465 | lastPoint.y + (lastPoint.y - lastControl.y)); |
466 | } else { | 466 | } else { |
@@ -493,7 +493,7 @@ class PdfGraphics { | @@ -493,7 +493,7 @@ class PdfGraphics { | ||
493 | case 's': // smooth cubic bézier, relative | 493 | case 's': // smooth cubic bézier, relative |
494 | while (points.length >= 4) { | 494 | while (points.length >= 4) { |
495 | PdfPoint c1; | 495 | PdfPoint c1; |
496 | - if ('cCsS'.indexOf(lastAction) >= 0) { | 496 | + if ('cCsS'.contains(lastAction)) { |
497 | c1 = PdfPoint(lastPoint.x + (lastPoint.x - lastControl.x), | 497 | c1 = PdfPoint(lastPoint.x + (lastPoint.x - lastControl.x), |
498 | lastPoint.y + (lastPoint.y - lastControl.y)); | 498 | lastPoint.y + (lastPoint.y - lastControl.y)); |
499 | } else { | 499 | } else { |
@@ -70,7 +70,7 @@ class PdfObject { | @@ -70,7 +70,7 @@ class PdfObject { | ||
70 | } | 70 | } |
71 | 71 | ||
72 | void _writeContent(PdfStream os) { | 72 | void _writeContent(PdfStream os) { |
73 | - if (params.length > 0) { | 73 | + if (params.isNotEmpty) { |
74 | os.putDictionary(params); | 74 | os.putDictionary(params); |
75 | os.putString("\n"); | 75 | os.putString("\n"); |
76 | } | 76 | } |
@@ -122,7 +122,7 @@ class PdfOutline extends PdfObject { | @@ -122,7 +122,7 @@ class PdfOutline extends PdfObject { | ||
122 | } | 122 | } |
123 | 123 | ||
124 | // These only valid if we have children | 124 | // These only valid if we have children |
125 | - if (outlines.length > 0) { | 125 | + if (outlines.isNotEmpty) { |
126 | // the number of the first outline in list | 126 | // the number of the first outline in list |
127 | params["/First"] = outlines[0].ref(); | 127 | params["/First"] = outlines[0].ref(); |
128 | 128 |
@@ -91,7 +91,7 @@ class PdfPage extends PdfObject { | @@ -91,7 +91,7 @@ class PdfPage extends PdfObject { | ||
91 | // } | 91 | // } |
92 | 92 | ||
93 | // the /Contents pages object | 93 | // the /Contents pages object |
94 | - if (contents.length > 0) { | 94 | + if (contents.isNotEmpty) { |
95 | if (contents.length == 1) { | 95 | if (contents.length == 1) { |
96 | params["/Contents"] = contents[0].ref(); | 96 | params["/Contents"] = contents[0].ref(); |
97 | } else { | 97 | } else { |
@@ -104,12 +104,12 @@ class PdfPage extends PdfObject { | @@ -104,12 +104,12 @@ class PdfPage extends PdfObject { | ||
104 | final resources = Map<String, PdfStream>(); | 104 | final resources = Map<String, PdfStream>(); |
105 | 105 | ||
106 | // fonts | 106 | // fonts |
107 | - if (fonts.length > 0) { | 107 | + if (fonts.isNotEmpty) { |
108 | resources["/Font"] = PdfStream()..putObjectDictionary(fonts); | 108 | resources["/Font"] = PdfStream()..putObjectDictionary(fonts); |
109 | } | 109 | } |
110 | 110 | ||
111 | // Now the XObjects | 111 | // Now the XObjects |
112 | - if (xObjects.length > 0) { | 112 | + if (xObjects.isNotEmpty) { |
113 | resources["/XObject"] = PdfStream()..putObjectDictionary(xObjects); | 113 | resources["/XObject"] = PdfStream()..putObjectDictionary(xObjects); |
114 | } | 114 | } |
115 | 115 | ||
@@ -121,7 +121,7 @@ class PdfPage extends PdfObject { | @@ -121,7 +121,7 @@ class PdfPage extends PdfObject { | ||
121 | } | 121 | } |
122 | 122 | ||
123 | // The /Annots object | 123 | // The /Annots object |
124 | - if (annotations.length > 0) { | 124 | + if (annotations.isNotEmpty) { |
125 | params["/Annots"] = PdfStream()..putObjectArray(annotations); | 125 | params["/Annots"] = PdfStream()..putObjectArray(annotations); |
126 | } | 126 | } |
127 | } | 127 | } |
@@ -2,7 +2,7 @@ name: pdf | @@ -2,7 +2,7 @@ name: pdf | ||
2 | author: David PHAM-VAN <dev.nfet.net@gmail.com> | 2 | author: David PHAM-VAN <dev.nfet.net@gmail.com> |
3 | description: A pdf producer for Dart. It can create pdf files for both web or flutter. | 3 | description: A pdf producer for Dart. It can create pdf files for both web or flutter. |
4 | homepage: https://github.com/DavBfr/dart_pdf/tree/master/pdf | 4 | homepage: https://github.com/DavBfr/dart_pdf/tree/master/pdf |
5 | -version: 1.3.0 | 5 | +version: 1.3.1 |
6 | 6 | ||
7 | environment: | 7 | environment: |
8 | sdk: ">=1.8.0 <3.0.0" | 8 | sdk: ">=1.8.0 <3.0.0" |
printing/analysis_options.yaml
0 → 100644
1 | +# Specify analysis options. | ||
2 | +# | ||
3 | +# Until there are meta linter rules, each desired lint must be explicitly enabled. | ||
4 | +# See: https://github.com/dart-lang/linter/issues/288 | ||
5 | +# | ||
6 | +# For a list of lints, see: http://dart-lang.github.io/linter/lints/ | ||
7 | +# See the configuration guide for more | ||
8 | +# https://github.com/dart-lang/sdk/tree/master/pkg/analyzer#configuring-the-analyzer | ||
9 | +# | ||
10 | +# There are other similar analysis options files in the flutter repos, | ||
11 | +# which should be kept in sync with this file: | ||
12 | +# | ||
13 | +# - analysis_options.yaml (this file) | ||
14 | +# - packages/flutter/lib/analysis_options_user.yaml | ||
15 | +# - https://github.com/flutter/plugins/blob/master/analysis_options.yaml | ||
16 | +# - https://github.com/flutter/engine/blob/master/analysis_options.yaml | ||
17 | +# | ||
18 | +# This file contains the analysis options used by Flutter tools, such as IntelliJ, | ||
19 | +# Android Studio, and the `flutter analyze` command. | ||
20 | + | ||
21 | +analyzer: | ||
22 | + strong-mode: | ||
23 | + implicit-dynamic: false | ||
24 | + errors: | ||
25 | + # treat missing required parameters as a warning (not a hint) | ||
26 | + missing_required_param: warning | ||
27 | + # treat missing returns as a warning (not a hint) | ||
28 | + missing_return: warning | ||
29 | + # allow having TODOs in the code | ||
30 | + todo: ignore | ||
31 | + # Ignore analyzer hints for updating pubspecs when using Future or | ||
32 | + # Stream and not importing dart:async | ||
33 | + # Please see https://github.com/flutter/flutter/pull/24528 for details. | ||
34 | + sdk_version_async_exported_from_core: ignore | ||
35 | + exclude: | ||
36 | + - 'bin/cache/**' | ||
37 | + # the following two are relative to the stocks example and the flutter package respectively | ||
38 | + # see https://github.com/dart-lang/sdk/issues/28463 | ||
39 | + - 'lib/i18n/stock_messages_*.dart' | ||
40 | + - 'lib/src/http/**' | ||
41 | + | ||
42 | +linter: | ||
43 | + rules: | ||
44 | + # these rules are documented on and in the same order as | ||
45 | + # the Dart Lint rules page to make maintenance easier | ||
46 | + # https://github.com/dart-lang/linter/blob/master/example/all.yaml | ||
47 | + - always_declare_return_types | ||
48 | + - always_put_control_body_on_new_line | ||
49 | + # - always_put_required_named_parameters_first # we prefer having parameters in the same order as fields https://github.com/flutter/flutter/issues/10219 | ||
50 | + - always_require_non_null_named_parameters | ||
51 | + - always_specify_types | ||
52 | + - annotate_overrides | ||
53 | + # - avoid_annotating_with_dynamic # conflicts with always_specify_types | ||
54 | + - avoid_as | ||
55 | + # - avoid_bool_literals_in_conditional_expressions # not yet tested | ||
56 | + # - avoid_catches_without_on_clauses # we do this commonly | ||
57 | + # - avoid_catching_errors # we do this commonly | ||
58 | + - avoid_classes_with_only_static_members | ||
59 | + # - avoid_double_and_int_checks # only useful when targeting JS runtime | ||
60 | + - avoid_empty_else | ||
61 | + - avoid_field_initializers_in_const_classes | ||
62 | + - avoid_function_literals_in_foreach_calls | ||
63 | + # - avoid_implementing_value_types # not yet tested | ||
64 | + - avoid_init_to_null | ||
65 | + # - avoid_js_rounded_ints # only useful when targeting JS runtime | ||
66 | + - avoid_null_checks_in_equality_operators | ||
67 | + # - avoid_positional_boolean_parameters # not yet tested | ||
68 | + # - avoid_private_typedef_functions # we prefer having typedef (discussion in https://github.com/flutter/flutter/pull/16356) | ||
69 | + - avoid_relative_lib_imports | ||
70 | + - avoid_renaming_method_parameters | ||
71 | + - avoid_return_types_on_setters | ||
72 | + # - avoid_returning_null # there are plenty of valid reasons to return null | ||
73 | + # - avoid_returning_null_for_future # not yet tested | ||
74 | + - avoid_returning_null_for_void | ||
75 | + # - avoid_returning_this # there are plenty of valid reasons to return this | ||
76 | + # - avoid_setters_without_getters # not yet tested | ||
77 | + # - avoid_shadowing_type_parameters # not yet tested | ||
78 | + # - avoid_single_cascade_in_expression_statements # not yet tested | ||
79 | + - avoid_slow_async_io | ||
80 | + - avoid_types_as_parameter_names | ||
81 | + # - avoid_types_on_closure_parameters # conflicts with always_specify_types | ||
82 | + - avoid_unused_constructor_parameters | ||
83 | + - avoid_void_async | ||
84 | + - await_only_futures | ||
85 | + - camel_case_types | ||
86 | + - cancel_subscriptions | ||
87 | + # - cascade_invocations # not yet tested | ||
88 | + # - close_sinks # not reliable enough | ||
89 | + # - comment_references # blocked on https://github.com/flutter/flutter/issues/20765 | ||
90 | + # - constant_identifier_names # needs an opt-out https://github.com/dart-lang/linter/issues/204 | ||
91 | + - control_flow_in_finally | ||
92 | + # - curly_braces_in_flow_control_structures # not yet tested | ||
93 | + - directives_ordering | ||
94 | + - empty_catches | ||
95 | + - empty_constructor_bodies | ||
96 | + - empty_statements | ||
97 | + # - file_names # not yet tested | ||
98 | + - flutter_style_todos | ||
99 | + - hash_and_equals | ||
100 | + - implementation_imports | ||
101 | + # - invariant_booleans # too many false positives: https://github.com/dart-lang/linter/issues/811 | ||
102 | + - iterable_contains_unrelated_type | ||
103 | + # - join_return_with_assignment # not yet tested | ||
104 | + - library_names | ||
105 | + - library_prefixes | ||
106 | + # - lines_longer_than_80_chars # not yet tested | ||
107 | + - list_remove_unrelated_type | ||
108 | + # - literal_only_boolean_expressions # too many false positives: https://github.com/dart-lang/sdk/issues/34181 | ||
109 | + - no_adjacent_strings_in_list | ||
110 | + - no_duplicate_case_values | ||
111 | + - non_constant_identifier_names | ||
112 | + # - null_closures # not yet tested | ||
113 | + # - omit_local_variable_types # opposite of always_specify_types | ||
114 | + # - one_member_abstracts # too many false positives | ||
115 | + # - only_throw_errors # https://github.com/flutter/flutter/issues/5792 | ||
116 | + - overridden_fields | ||
117 | + - package_api_docs | ||
118 | + - package_names | ||
119 | + - package_prefixed_library_names | ||
120 | + # - parameter_assignments # we do this commonly | ||
121 | + - prefer_adjacent_string_concatenation | ||
122 | + - prefer_asserts_in_initializer_lists | ||
123 | + - prefer_collection_literals | ||
124 | + - prefer_conditional_assignment | ||
125 | + - prefer_const_constructors | ||
126 | + - prefer_const_constructors_in_immutables | ||
127 | + - prefer_const_declarations | ||
128 | + - prefer_const_literals_to_create_immutables | ||
129 | + # - prefer_constructors_over_static_methods # not yet tested | ||
130 | + - prefer_contains | ||
131 | + - prefer_equal_for_default_values | ||
132 | + # - prefer_expression_function_bodies # conflicts with https://github.com/flutter/flutter/wiki/Style-guide-for-Flutter-repo#consider-using--for-short-functions-and-methods | ||
133 | + - prefer_final_fields | ||
134 | + - prefer_final_locals | ||
135 | + - prefer_foreach | ||
136 | + # - prefer_function_declarations_over_variables # not yet tested | ||
137 | + - prefer_generic_function_type_aliases | ||
138 | + - prefer_initializing_formals | ||
139 | + # - prefer_int_literals # not yet tested | ||
140 | + # - prefer_interpolation_to_compose_strings # not yet tested | ||
141 | + - prefer_is_empty | ||
142 | + - prefer_is_not_empty | ||
143 | + - prefer_iterable_whereType | ||
144 | + # - prefer_mixin # https://github.com/dart-lang/language/issues/32 | ||
145 | + - prefer_single_quotes | ||
146 | + - prefer_typing_uninitialized_variables | ||
147 | + - prefer_void_to_null | ||
148 | + # - public_member_api_docs # enabled on a case-by-case basis; see e.g. packages/analysis_options.yaml | ||
149 | + - recursive_getters | ||
150 | + - slash_for_doc_comments | ||
151 | + - sort_constructors_first | ||
152 | + - sort_pub_dependencies | ||
153 | + - sort_unnamed_constructors_first | ||
154 | + - super_goes_last | ||
155 | + - test_types_in_equals | ||
156 | + - throw_in_finally | ||
157 | + # - type_annotate_public_apis # subset of always_specify_types | ||
158 | + - type_init_formals | ||
159 | + # - unawaited_futures # too many false positives | ||
160 | + # - unnecessary_await_in_return # not yet tested | ||
161 | + - unnecessary_brace_in_string_interps | ||
162 | + - unnecessary_const | ||
163 | + - unnecessary_getters_setters | ||
164 | + # - unnecessary_lambdas # has false positives: https://github.com/dart-lang/linter/issues/498 | ||
165 | + - unnecessary_new | ||
166 | + - unnecessary_null_aware_assignments | ||
167 | + - unnecessary_null_in_if_null_operators | ||
168 | + - unnecessary_overrides | ||
169 | + - unnecessary_parenthesis | ||
170 | + - unnecessary_statements | ||
171 | + - unnecessary_this | ||
172 | + - unrelated_type_equality_checks | ||
173 | + # - use_function_type_syntax_for_parameters # not yet tested | ||
174 | + - use_rethrow_when_possible | ||
175 | + # - use_setters_to_change_properties # not yet tested | ||
176 | + # - use_string_buffers # has false positives: https://github.com/dart-lang/sdk/issues/34182 | ||
177 | + # - use_to_and_as_if_applicable # has false positives, so we prefer to catch this by code-review | ||
178 | + - valid_regexps | ||
179 | + # - void_checks # not yet tested |
@@ -2,7 +2,7 @@ name: printing | @@ -2,7 +2,7 @@ name: printing | ||
2 | author: David PHAM-VAN <dev.nfet.net@gmail.com> | 2 | author: David PHAM-VAN <dev.nfet.net@gmail.com> |
3 | description: Plugin that allows Flutter apps to generate and print documents to android or ios compatible printers | 3 | description: Plugin that allows Flutter apps to generate and print documents to android or ios compatible printers |
4 | homepage: https://github.com/DavBfr/dart_pdf/tree/master/printing | 4 | homepage: https://github.com/DavBfr/dart_pdf/tree/master/printing |
5 | -version: 1.3.0 | 5 | +version: 1.3.1 |
6 | 6 | ||
7 | environment: | 7 | environment: |
8 | sdk: ">=1.19.0 <3.0.0" | 8 | sdk: ">=1.19.0 <3.0.0" |
-
Please register or login to post a comment