V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
iOS 开发实用技术导航
NSHipster 中文版
http://nshipster.cn/
cocos2d 开源 2D 游戏引擎
http://www.cocos2d-iphone.org/
CocoaPods
http://cocoapods.org/
Google Analytics for Mobile 统计解决方案
http://code.google.com/mobile/analytics/
WWDC
https://developer.apple.com/wwdc/
Design Guides and Resources
https://developer.apple.com/design/
Transcripts of WWDC sessions
http://asciiwwdc.com
Cocoa with Love
http://cocoawithlove.com/
Cocoa Dev Central
http://cocoadevcentral.com/
NSHipster
http://nshipster.com/
Style Guides
Google Objective-C Style Guide
NYTimes Objective-C Style Guide
Useful Tools and Services
Charles Web Debugging Proxy
Smore
pysama
V2EX  ›  iDev

可否用写 HTML 结构的方式来写 iOS 的界面?

  •  
  •   pysama · 2015-06-08 22:53:31 +08:00 · 2938 次点击
    这是一个创建于 3257 天前的主题,其中的信息可能已经有所发展或是发生改变。

    个人觉得在storyboard中处理布局就像用dreamweaver可视化做网页一样,不是很高效。(特别是一个SB中有多个view的时候,打开都特别慢)

    有没有办法可以像写html结构一样来写iOS 的界面呢?在类文件中通过id或者tag就可以控制ui控件的表现。

    17 条回复    2015-06-09 15:58:09 +08:00
    w88975
        1
    w88975  
       2015-06-08 22:58:05 +08:00   ❤️ 1
    React native
    hybrid APP
    l12ab
        2
    l12ab  
       2015-06-08 23:10:44 +08:00
    你可以全手写界面,能复用的尽量复用,某些参数可以作为常量的就作为常量
    janxin
        3
    janxin  
       2015-06-08 23:13:01 +08:00 via iPad
    可以,国人有个开源项目就是实现类似功能的
    qq2511296
        4
    qq2511296  
       2015-06-08 23:15:36 +08:00
    BeeFramework
    wezzard
        5
    wezzard  
       2015-06-08 23:52:05 +08:00 via iPhone
    Opening your storyboard file in code editor will make your dream come true.
    hging
        6
    hging  
       2015-06-08 23:52:19 +08:00
    ionic
    ipconfiger
        7
    ipconfiger  
       2015-06-09 00:42:03 +08:00
    用Masonry,就跟手写CSS感觉差不多
    df4VW
        8
    df4VW  
       2015-06-09 02:28:20 +08:00
    react native
    pysama
        9
    pysama  
    OP
       2015-06-09 09:21:26 +08:00
    @l12ab
    @wezzard 您是说在xcode中直接编辑xml嘛?
    pysama
        10
    pysama  
    OP
       2015-06-09 09:21:45 +08:00
    @qq2511296 关注下
    pysama
        11
    pysama  
    OP
       2015-06-09 09:22:06 +08:00
    多谢LS其他朋友的建议,我优化完手头demo了,一起看看那
    typcn
        12
    typcn  
       2015-06-09 09:39:12 +08:00
    iOS 程序直接用 HTML 都没问题,很流畅
    wezzard
        13
    wezzard  
       2015-06-09 09:57:49 +08:00
    @pysama Yes.
    likid
        14
    likid  
       2015-06-09 10:05:21 +08:00
    “特别是一个SB中有多个view的时候,打开都特别慢”

    你该升级硬件了

    可以拆分多个 SB 出来
    ajan
        15
    ajan  
       2015-06-09 10:50:50 +08:00
    janxin
        16
    janxin  
       2015-06-09 11:09:14 +08:00
    @ajan 这个是hybird的App跟原生界面不是一个概念的
    pysama
        17
    pysama  
    OP
       2015-06-09 15:58:09 +08:00
    @likid 我14年的rmbp,还好吧。。
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   我们的愿景   ·   实用小工具   ·   4402 人在线   最高记录 6543   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 32ms · UTC 05:23 · PVG 13:23 · LAX 22:23 · JFK 01:23
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.