Good topic. For sure, we don't want to require Iframe. A related topic is Jude's suggestion to allow for different HTML Templates instead of the one that we currently generate.
Currently Application is sort of assuming it wraps everything. IMO, there might be more than just a search for hostID required to have it be a part of the HTML especially if it has to co-exist with another FlexJS app in the same body. Where do Scripts get injected, for example? There is a vision for FlexJS where it "always" wraps everything and other HTML you might have put in your template is just in the MXML so the MXML serves as the template. Before we make any changes here, I'd like to finish the Application/FactoryClass changes just to save on merge hassle. Thoughts? -Alex On 7/31/16, 2:21 AM, "Harbs" <[email protected]> wrote: >Right now a FlexJS Application is always being attached to the <body> tag >and the width/size etc. is assumed to be the whole browser window. > >This is problematic. There’s plenty of applications where the app is a >specific part of a web page with a header, footer, navigation, etc. > >Now, before someone tells me we can just always embed an application in >an iframe, let me tell you that it’s not always an option. The biggest >stumbling block is a major bug in iOS where the virtual keyboard is not >available to apps within iframes. This caused me to give iOS special >handling of an HTML app I wrote to use a div instead of an iframe. > >I think we should add a “hostID” property to Application which >Application would use to find the div it attaches itself to at startup. >There should also be x,y,width,height and alpha properties on Application >to get this info on the div. In fact, I think an Application should be an >IUIBase. > >I’ll be happy to make these changes, but I wanted to discuss this before >I do. > >Harbs
