zhenpengzhu
V2EX  ›  Flutter

flutter 在 ListView 中放置 Flexible 我要怎么做

  •  
  •   zhenpengzhu · Jun 8, 2023 · 1509 views
    This topic created in 1073 days ago, the information mentioned may be changed or developed.

    我想在我的 ListView 里面放置很多大小不确定的 Flexible 我要怎么做。ListView 不能直接放置 Flexible ,Flexible 需要知道父组件约束条件。但我各个 Flexible 高度又相差很大,不想给它套 Container 固定住它的高度。

    dabbit
        1
    dabbit  
       Jun 9, 2023
    不如试试 SingleChildScrollView
    jifengg
        2
    jifengg  
       Jun 9, 2023
    楼主,你是要实现什么样的效果呢?高度不一的 widget ,可以直接放 ListView 里。
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   3113 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 36ms · UTC 13:06 · PVG 21:06 · LAX 06:06 · JFK 09:06
    ♥ Do have faith in what you're doing.