Conversation
|
@eyebrowsoffire ptal. @ditman, @mdebbar FYI, please feel free to review if you like. |
ditman
left a comment
There was a problem hiding this comment.
LGTM if @eyebrowsoffire likes it.
| @JS('_flutter') | ||
| external set loader(Object? loader); | ||
| external set _loader(JSAny? loader); | ||
| set loader(Object? l) => _loader = l?.toJSAnyShallow; |
There was a problem hiding this comment.
Took me a while to figure out why this was a setter (it's a test 🤦)
There was a problem hiding this comment.
I may be misunderstanding something here, but isn't this redundant with the js_util.jsify(...) calls below?
set loader(Object? l) => _loader = l?.toJSAnyShallow;
// in tests:
loader = js_util.jsify(<String, Object>{
'loader': <String, Object>{
'didCreateEngineInitializer': allowInterop(() { print('not mocked'); }),
},
});There was a problem hiding this comment.
Ahh yea, good catch, it is redundant. I'm not actually trying to investigate usage patterns too deeply at this phase of the migration, mostly to derisk the conversion. That said, this is a good candidate for cleanup when we try to push JS types deeper into the Web engine. Thankfully this is a test, and jsify now has fast paths for types it doesn't need to convert.
eyebrowsoffire
left a comment
There was a problem hiding this comment.
Looks great! I have one comment... it's not necessarily blocking but it would be really nice if you had the time to do it.
ef4ac03 to
2943832
Compare
…23217) Commit: b42e8db6cf8f7aa0e8debb7dec423b9080d3727f
No description provided.