Return-Path: X-Original-To: apmail-cordova-dev-archive@www.apache.org Delivered-To: apmail-cordova-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id F1A4A10C14 for ; Sat, 15 Feb 2014 18:35:18 +0000 (UTC) Received: (qmail 85725 invoked by uid 500); 15 Feb 2014 18:35:18 -0000 Delivered-To: apmail-cordova-dev-archive@cordova.apache.org Received: (qmail 85641 invoked by uid 500); 15 Feb 2014 18:35:17 -0000 Mailing-List: contact dev-help@cordova.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cordova.apache.org Delivered-To: mailing list dev@cordova.apache.org Received: (qmail 85632 invoked by uid 99); 15 Feb 2014 18:35:17 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 15 Feb 2014 18:35:17 +0000 X-ASF-Spam-Status: No, hits=-0.7 required=5.0 tests=RCVD_IN_DNSWL_LOW,SPF_HELO_PASS,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of jbondc@gdesolutions.com designates 207.46.163.153 as permitted sender) Received: from [207.46.163.153] (HELO na01-bn1-obe.outbound.protection.outlook.com) (207.46.163.153) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 15 Feb 2014 18:35:10 +0000 Received: from BN1PR07MB135.namprd07.prod.outlook.com (10.242.216.22) by BN1PR07MB134.namprd07.prod.outlook.com (10.242.216.20) with Microsoft SMTP Server (TLS) id 15.0.878.16; Sat, 15 Feb 2014 18:34:46 +0000 Received: from BN1PR07MB135.namprd07.prod.outlook.com ([169.254.15.30]) by BN1PR07MB135.namprd07.prod.outlook.com ([169.254.15.30]) with mapi id 15.00.0878.008; Sat, 15 Feb 2014 18:34:46 +0000 From: Jonathan Bond-Caron To: "dev@cordova.apache.org" Subject: RE: XML Namespaces Thread-Topic: XML Namespaces Thread-Index: AQHPKD392W+BJWekVk6pXYQrHku3upqyMkuggAEPZwCAAAFP8IAB4uoAgAF/avA= Date: Sat, 15 Feb 2014 18:34:46 +0000 Message-ID: <5786ff99cd2249b5ac5f21062393c7c1@BN1PR07MB135.namprd07.prod.outlook.com> References: <625597b81d584977ba20656fd09466bd@BN1PR07MB135.namprd07.prod.outlook.com> <53BB8282-24D2-40BD-8988-A7AA5E4660BC@gmail.com> In-Reply-To: <53BB8282-24D2-40BD-8988-A7AA5E4660BC@gmail.com> Accept-Language: en-CA, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [24.201.199.160] x-forefront-prvs: 012349AD1C x-forefront-antispam-report: SFV:NSPM;SFS:(10009001)(6009001)(51704005)(377454003)(24454002)(189002)(199002)(95416001)(4396001)(49866001)(19580405001)(79102001)(33646001)(47446002)(87936001)(59766001)(80976001)(65816001)(80022001)(85306002)(76786001)(76796001)(66066001)(92566001)(31966008)(76576001)(19580395003)(81816001)(77982001)(74662001)(54316002)(95666001)(74502001)(47736001)(81686001)(77096001)(2656002)(93136001)(87266001)(47976001)(50986001)(83322001)(15975445006)(56776001)(74366001)(46102001)(83072002)(85852003)(53806001)(74876001)(93516002)(54356001)(56816005)(74706001)(94946001)(51856001)(221733001)(86362001)(81542001)(63696002)(69226001)(94316002)(74316001)(81342001)(90146001)(24736002);DIR:OUT;SFP:1101;SCL:1;SRVR:BN1PR07MB134;H:BN1PR07MB135.namprd07.prod.outlook.com;CLIP:24.201.199.160;FPR:24EDF015.AE169DE2.F7FC3533.40E5F471.20293;PTR:InfoNoRecords;MX:1;A:1;LANG:en; Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: gdesolutions.com X-Virus-Checked: Checked by ClamAV on apache.org On Fri Feb 14 02:30 PM, Marcel Kinard wrote: >=20 > On Feb 13, 2014, at 10:04 AM, Jonathan Bond-Caron > wrote: >=20 > > IBM most likely would prefer XML for the XSD & tooling... >=20 > Not necessarily. Schema validation is nice, but XML for the sake of XML d= oesn't > make sense. What makes more sense is following standards where reasonably > possible. But if the widget spec is deprecated and we are making a consci= ous > decision to abandon it, then the leaning for XML goes away. Given the aud= ience > of web devs, and the use of json config in other places, my preference wo= uld be > for json config.=20 Great to have your opinion, my guesswork was that for a plugman based proje= ct on android for example, xml would be preferred. >=20 > > Note about xml vs. json config, Cordova could support both. >=20 > Cordova could, but that seems to me like overkill. If someone really want= s xml, > how about providing an xslt that translates the xml to json, so they can = author in > xml and Cordova could read json. But even that sounds like overkill too. It turns out there's a great node lib called 'xml2js', the code to do this = is pretty simple: https://github.com/jbondc/cordova-labs/blob/master/cordova-lib/test.js https://github.com/jbondc/cordova-labs/blob/master/cordova-lib/config.ts https://github.com/jbondc/cordova-labs/blob/master/cordova-lib/config.js So the idea here is: - config.xml, config.json - plugin.xml, plugin.json=20 Would both be supported, with json being looked for first.