
获得徽章 24
- #Trae又又又更新了#
Trae 的护城河在哪?之前我一直以为它的亮点是【Builder】模式,把任务拆解成多个小任务,一步步完成 (IDE才有,插件没有)。但这两天我发现 Github Copilot、百度Zulu 这两个插件都新增了一个【Agent-智能体】的模式,功能基本一致。
赞过评论1 - #挑战每日一条沸点# 【Flutter-Bug小记】
同事遇到的UI问题
问题描述:
【Expanded】控件在 Debug 模式显示正常,Release 模式直接不显示。
问题原因:
直接在 Container 中使用 Expanded 组件❗️ 而 Expanded、Flexible 组件只能在 Row、Column、Flex 中使用,🤷♀️ 其实在Debug模式也会抛出下述异常:
======== Exception caught by widgets library =======================================================
The following assertion was thrown while applying parent data.:
Incorrect use of ParentDataWidget.
The ParentDataWidget Expanded(flex: 1) wants to apply ParentData of type FlexParentData to a RenderObject, which has been set up to accept ParentData of incompatible type ParentData.
Usually, this means that the Expanded widget has the wrong ancestor RenderObjectWidget. Typically, Expanded widgets are placed directly inside Flex widgets.
The offending Expanded is currently placed inside a ColoredBox widget.
解法:
套个Row、Column、Flex 就好了,或者不用 Expanded 组件~展开评论点赞