Skip to content

Plist Integration

jasperblues edited this page Dec 23, 2014 · 5 revisions

##Plist integration (fully Typhoon-powered apps).

Tight integration is available for an app that is fully Typhoon-powered. This has the following advantages:

  • Non-invasive : No references to Typhoon in your code-base, except for resolution of components via assembly interfaces.
  • Supports UIStateRestoration in storyboards.

Declare Typhoon Assemblies in App-info plist.

Edit Plist

If you have a specific iPhone or iPad assembly, the following keys take precedence over 'TyphoonInitialAssemblies'

  • TyphoonInitialAssemblies(iPhone)
  • TyphoonInitialAssemblies(iPad)

Define injections for App Delegate

- (AppDelegate *)appDelegate
{
    return [TyphoonDefinition withClass:[AppDelegate class] 
        configuration:^(TyphoonDefinition *definition)
        {
            [definition injectProperty:@selector(rootController)
                 with:[self rootController]];
        }];
}

##Storyboards

If your application has Storyboards and your plist contains a UILaunchStoryboardName and UIMainStoryboardFile then Typhoon's Storyboards support will be available.