Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

UIP-1637 First pass at strong mode compliance #15

Merged
merged 30 commits into from
Nov 2, 2016
Merged
Show file tree
Hide file tree
Changes from 11 commits
Commits
Show all changes
30 commits
Select commit Hold shift + click to select a range
27c1a59
First pass at strong mode compliance
aaronlademann-wf Oct 28, 2016
f2a5cc6
Get rid of two more implicit type casts
aaronlademann-wf Oct 28, 2016
f1c6657
Use https to see if travis likes that better
aaronlademann-wf Oct 28, 2016
17f16fa
Get rid of two implicit casts that don’t cause warnings on my machine
aaronlademann-wf Oct 28, 2016
2804edf
Cast in the test instead of changing the type of the method
aaronlademann-wf Oct 28, 2016
d9071f8
Change Function to ReactComponent
aaronlademann-wf Oct 28, 2016
af8d5f9
Remove redundant left hand side typing
aaronlademann-wf Oct 28, 2016
2914187
Turn on strong mode for integrate directory
aaronlademann-wf Oct 28, 2016
3b51626
Undo pubspec path commit
aaronlademann-wf Oct 28, 2016
0e7c44a
Fix implicit cast
aaronlademann-wf Oct 28, 2016
c2299be
Add test coverage for string UiComponent.ref
aaronlademann-wf Oct 28, 2016
fc1b96e
Use the typedef from react-dart
aaronlademann-wf Oct 31, 2016
b76c072
Don’t commit integrate/pubspec.lock
aaronlademann-wf Oct 31, 2016
fe69d03
Ignore all pubspec.lock files
aaronlademann-wf Oct 31, 2016
46639f2
Bump min sdk to 1.19.1
aaronlademann-wf Oct 31, 2016
047a8a9
Merge 'aaronlademann-wf/sdk_1.19.1' into strong-mode-ftw
aaronlademann-wf Oct 31, 2016
9d6a136
Remove unnecessary casts
aaronlademann-wf Oct 31, 2016
0fe7556
Parameterize Lists / Maps for 1.20.1 strong mode compliance
aaronlademann-wf Nov 1, 2016
2507729
Remove unnecessary casting
aaronlademann-wf Nov 1, 2016
1b4a80a
Enable avoid_as lint
aaronlademann-wf Nov 1, 2016
d205ea9
Add casting to fix broken VM tests
aaronlademann-wf Nov 1, 2016
5547f8d
Fix the vm test errors a better way
aaronlademann-wf Nov 1, 2016
c4dd932
Fix analysis error when sdk version is > 1.20.1
aaronlademann-wf Nov 1, 2016
f211b71
Update react dependency to ^3.0.1
aaronlademann-wf Nov 1, 2016
ba742e8
Remove unnecessary test file
aaronlademann-wf Nov 1, 2016
dd869c5
Address CR feedback
aaronlademann-wf Nov 1, 2016
c8b41b7
Parameterize Expando
aaronlademann-wf Nov 1, 2016
98917e9
Fix some formatting anomalies
aaronlademann-wf Nov 1, 2016
9a91b1d
Exclude integrate/ directory from analyzer
aaronlademann-wf Nov 1, 2016
1dbb92f
Address CR feedback
aaronlademann-wf Nov 1, 2016
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions .analysis_options
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
analyzer:
exclude:
- integrate/**
strong-mode: true
linter:
rules:
- annotate_overrides
Expand Down
5 changes: 2 additions & 3 deletions integrate/lib/test_component_declaration.dart
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,7 @@

library test_component_declaration;

import 'package:over_react/ui_core.dart';
import 'package:over_react/ui_components.dart';
import 'package:over_react/over_react.dart';

@Factory()
UiFactory<FooProps> Foo;
Expand All @@ -30,7 +29,7 @@ class FooState extends UiState {}
class FooComponent extends UiStatefulComponent<FooProps, FooState> {
@override
render() {
return Button()(
return Dom.div()(
'Child 1',
'Child 2'
);
Expand Down
11 changes: 9 additions & 2 deletions integrate/lib/test_react_element_typing.dart
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,14 @@ import './test_component_declaration.dart';

/// Verify that treating the invocation of the builder as an unparameterized [ReactElement]
/// does not result in the following analyzer warning:
/// > Unsound implicit cast from ReactElement<dynamic> to ReactElement<Component>
void _reactElementTypingTest() {
///
/// Unsound implicit cast from ReactElement<dynamic> to ReactElement<Component>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ReactElement no longer has a generic parameter as of a breaking release or two ago, so we can probably just remove this whole file.

ReactElement _reactElementTypingTest() {
ReactElement element = Foo()();

return element;
}

main() {
_reactElementTypingTest();
}
Loading