Is there a special meaning to class names that start with a dollar sign ($)?

浪尽此生 提交于 2021-02-11 12:14:59

问题


Like in this example: https://github.com/brianegan/github_search_angular_flutter/blob/master/github_search_common/lib/src/ui/search_state.dart

The class is referenced to without the dollar sign in other parts of the code. I couldn't find any documentation about this.


回答1:


$ is a valid character for any name in Dart. In this case, it looks like the convention for https://pub.dartlang.org/packages/meta_types

I'd look at that documentation.



来源:https://stackoverflow.com/questions/52729086/is-there-a-special-meaning-to-class-names-that-start-with-a-dollar-sign

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!