flutter - What does 'new' mean in Flutter?
问题描述
Is there a difference between the following two statements in Dart?
new Container()
// vs
Container()
解决方案
There is no difference. The new
keyword was mandatory at some point, but was made optional with Dart version 2.
See this answer for more information. You can also mark your question as a duplicate above using the comment I posted.
推荐阅读
- mediawiki - 如何允许 MediaWiki 创建 Transclusion_Count/data 页面
- r - R- Rcpp 和 Amelia R 包的问题
- neo4j - 查找与条件匹配但不能具有具有某些属性的中间节点的最近节点
- mysql - Elasticsearch如何实现如下SQL语句
- java - 无法运行 OptaPlanner 以优化 Eclipse 中的学校时间表示例
- rust - 在 usize 中检查整数溢出的规范方法
- css - 由于媒体查询,CSS Grid 未从单列转换为单行
- python - 悬停回调问题 - 不显示数据框
- python - 通过 pyton shell 脚本激活的 conda 不能通过导入运行
- javascript - 如何仅返回文本作为 Google Apps 脚本对 Telegram 内联查询的响应?