incubator-callback-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Filip Maj <...@adobe.com>
Subject Re: Checking platform + version in cordova-js
Date Fri, 04 May 2012 15:58:20 GMT


On 5/3/12 4:54 PM, "Patrick Mueller" <pmuellr@gmail.com> wrote:

>So, the .js knows what platform it was built for.  We should create a
>marker in cordova.js, near the top, making it real obvious what platform
>it's for.  Should also be machine readable.

Are you thinking a comment near the top "HEY THIS IS FOR BLACKBERRY
PPLZ!!!" ?

>Perhaps there's no way to do make the platform check, in one single
>portable way, across platforms.  Every platform may have to do the best
>they can.  Maybe checking user agent on some particular platform actually
>makes sense (BUT I DOUBT IT!).

Actually user agent checking might be worth looking into. I'll play around
with that. Thanks for the suggestion Pat!


>eg, for iOS, if we did as I suggest in the 1st paragraph, we could easily
>check this in an Xcode build step in our template, and (I assume) force a
>build failure.
>
>And once we have the "command line tooling", maybe we can check there
>also.

Once tooling is in place I think we can be a bit more strict. In a single
app project, we know which platforms the user is targeting. We have direct
control over the directory structure and all the bits. We can be as
brute-force as overwriting any phonegap/cordova.js files, for example.


Mime
View raw message