Closed kevinresol closed 4 years ago
class Main extends coconut.ui.View { @:attr var foo:String->Void; static function main() {} function render() '<div/>'; static function getDerivedStateFromAttributes(attrs) return {} }
gives: Explicit type required for field foo
Explicit type required for field foo
this works:
@:attr function foo(s:String):Void;
Somehow the function argument type (String) is lost when specified by the var syntax. args: [{name: a0, opt: false, type: null}]
var
args: [{name: a0, opt: false, type: null}]
gives:
Explicit type required for field foo