gpt4 book ai didi

ios - 如何让 Pixate v2 实时 CSS 与 Xcode 5 一起工作

转载 作者:行者123 更新时间:2023-11-29 10:50:51 27 4
gpt4 key购买 nike

我已经成功地让 pixate 2.0.1 在 ios 7 项目上与 XCode 5 一起工作。实际上它真的很棒!如果使用实时 CSS,它会更棒。这基本上是 iPhone/iPad 模拟器在编辑和保存 css 文件时实时更新的地方。现在一切都是樱桃。但不幸的是我还不能让它工作。我按照 Paul Colton 在这里给出的指示进行操作:http://youtu.be/rjNrNIyEL_c .但它适用于 Pixate 的版本 1,并使用现已过时的 PXEngine 语法。

有人知道如何在 Pixate 2.0.1 版中使用它吗?

最佳答案

假设您已按照此处找到的安装版本 2.x 的最新说明进行操作:http://www.pixate.com/docs/framework/ios/latest/getting-started/

然后确保您的 AppDelegate 中包含以下内容:

- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
{
//Initalize Pixate
self.window.styleMode = PXStylingNormal;

//Dynamically modify the Pixate stylesheet while the Simulator is running
#ifdef DEBUG
[Pixate styleSheetFromFilePath:@"/Users/YourHomeFolder/Path/To/default.css" withOrigin:PXStylesheetOriginApplication];
Pixate.currentApplicationStylesheet.monitorChanges = YES;
#endif
}

希望对您有所帮助。

关于ios - 如何让 Pixate v2 实时 CSS 与 Xcode 5 一起工作,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/20526864/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com