From dev-return-7466-archive-asf-public=cust-asf.ponee.io@royale.apache.org Fri Nov 2 18:44:23 2018 Return-Path: X-Original-To: archive-asf-public@cust-asf.ponee.io Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by mx-eu-01.ponee.io (Postfix) with SMTP id AD03D18062B for ; Fri, 2 Nov 2018 18:44:22 +0100 (CET) Received: (qmail 23528 invoked by uid 500); 2 Nov 2018 17:44:21 -0000 Mailing-List: contact dev-help@royale.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@royale.apache.org Delivered-To: mailing list dev@royale.apache.org Received: (qmail 23516 invoked by uid 99); 2 Nov 2018 17:44:21 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd4-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 02 Nov 2018 17:44:21 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd4-us-west.apache.org (ASF Mail Server at spamd4-us-west.apache.org) with ESMTP id AF691C056E for ; Fri, 2 Nov 2018 17:44:20 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd4-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 3.201 X-Spam-Level: *** X-Spam-Status: No, score=3.201 tagged_above=-999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, HTML_MESSAGE=2, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_PASS=-0.001, T_DKIMWL_WL_MED=-0.01, URI_HEX=1.313] autolearn=disabled Authentication-Results: spamd4-us-west.apache.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd4-us-west.apache.org [10.40.0.11]) (amavisd-new, port 10024) with ESMTP id 7nL8P4zImJz0 for ; Fri, 2 Nov 2018 17:44:18 +0000 (UTC) Received: from mail-oi1-f182.google.com (mail-oi1-f182.google.com [209.85.167.182]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with ESMTPS id 91C5C5F27D for ; Fri, 2 Nov 2018 17:44:17 +0000 (UTC) Received: by mail-oi1-f182.google.com with SMTP id k19-v6so2224745oic.11 for ; Fri, 02 Nov 2018 10:44:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to; bh=UBaXDkuO+ksD3ZhOB0aBURvpZJFsQN7A+JFeQa1GTCg=; b=PX9JX0X5xANVN9WGgX7YzJiprqyevsN5UCAimSsa+1KAnwcy6DjV+lg+KH7+9vElHF /Zl2cK8rkLCSXJH6ilRFmYCEtTDoOaI32JJR8icS6l5ddvHXI+xJ4XWh8Lc0LJ+uNgFW MN7l/dEDWl8a5Msyl6BLNKl9pBubyl6D//S9mlG+k9I0JcinAGowovbnzZsvDWEJZVN9 oWTuwcaVTX7GT+PPObvu3UI5+tAxUobJ/EnCVdeXSJebZBx2safgfYzN4XhZHtVv8C0o YxTcLgGFCoZxOzx3ddOjzqEXmLMK8uV/0dgY0kVszkRP30qspAoNSgxuatXhCrsZhNQj OAhw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to; bh=UBaXDkuO+ksD3ZhOB0aBURvpZJFsQN7A+JFeQa1GTCg=; b=neSHEGUSXUdUKjl9wO6oeU9eVMzi+c4254KjOKAaRgCB3Bl92CetVBkh4RCQrUAOZz ZAwommm+9y75k2O1TmWiVnSx4GQo22AHKf7fwjAg+iX98FpusSdHsbBa0kxvp5BwFkYf J2p/30s/pGGMX4gNk1ETiGsj9L2rToQxyoWn4huBAN1zfQnqiEdJ3lo9cvj4ho8+Uqjc Ugw3a+kJ3GMJaihE+zhLs+TjaahbrB+X+l8lhdPMa7QA+Ojz7VSdeBdvCIliSPIJDIEf PY24iWDaherv4Vec4FzGKAXRRNoJEdAEVop0A8tu1PRMW8VVNlPGWzHUUKr6ZxBlRzjw jSUg== X-Gm-Message-State: AGRZ1gK0SMrdCyYf+l2EhO5n6YenOMbq+HsWIk7svSPMHNPhLQHZuBMg PYRFVhQ9nj1f4hEu/wGqHnQYfYLTAaTXef7B/Kwktw9U X-Google-Smtp-Source: AJdET5cyzPQshpQuUVA8rZnCNNLfdjRHnLuHeiwWATg8uA+2roBhZ62r6iMtGZjQWaqPzaMbNEGEW1i34B/ENRrqhgQ= X-Received: by 2002:a54:448b:: with SMTP id v11-v6mr1382993oiv.128.1541180655811; Fri, 02 Nov 2018 10:44:15 -0700 (PDT) MIME-Version: 1.0 References: <19E3A08F-BA37-43FC-BA9C-5A8438AE91EA@gmail.com> In-Reply-To: <19E3A08F-BA37-43FC-BA9C-5A8438AE91EA@gmail.com> From: Greg Dove Date: Sat, 3 Nov 2018 06:44:06 +1300 Message-ID: Subject: Re: Revisiting the old debate: 'localId vs. id' To: dev@royale.apache.org Content-Type: multipart/alternative; boundary="0000000000008644000579b2150b" --0000000000008644000579b2150b Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Hi Harbs, thanks for that feedback. I do agree that using both localId and id is unlikely and should probably cause a compiler error if used as it stands currently. Which one wins? At the moment it is possible and id wins, so yes it would make sense for the conflict to be a compiler error. How many people are using legacy IDEs for Royale? I still use IntelliJ, although I will try VSCode soon. 'I don=E2=80=99t think it=E2=80=99s a good idea to make id default to not c= reating DOM ids. That would invalidate CSS for the id.' How often in practice do you use external id targeting for css styling? I think mostly it is class (className) based, isn't it? I'm no expert on CSS styling, but my impression is that the use of ids for styling in css is minimal (because it is specific). If it is rare, then presumably it is not a lot of work to switch it on for specific cases. But the idea for defaults was more to let the default be configurable: as-it-is now or opposite. I've been doing React work for almost 18 months now, and in that experience use of element level 'id' in jsx (which is propagated to DOM) is extremely rare. Perhaps my experience is not representative, but it has also influenced the way I think about this. And React also has a different paradigm and has a more explicit notion of local references being separate from 'id' in any case. I'm only mentioning this to compare, I'm happy to be doing more actionscript/mxml :) On Fri, Nov 2, 2018 at 10:09 PM Harbs wrote: > I tend to like Greg=E2=80=99s suggestion, but I don=E2=80=99t feel strong= ly on the subject > one way or another. > > I do agree that using both localId and id is unlikely and should probably > cause a compiler error if used as it stands currently. Which one wins? > > I=E2=80=99ve actually never used localId, although I possibly should have= . Taking > VS Code as an example, it seems like there=E2=80=99s no code hinting for = localId > currently, but it is correctly verified when used. How many people are > using legacy IDEs for Royale? > > I don=E2=80=99t think it=E2=80=99s a good idea to make id default to not = creating DOM ids. > That would invalidate CSS for the id. > > My $0.02, > Harbs > > > On Nov 2, 2018, at 11:01 AM, Piotr Zarzycki > wrote: > > > > Hi Greg, > > > > I'm really happy that you are helping Carlos with that! He may move > forward > > much faster. I just have question to following: > > > > "-My understanding is that best practice is to avoid multiple identical > ids > > in the browser, irrespective of whether the browser is forgiving of tha= t > or > > not. If so, it might be good to have at least an option to set the > default > > implementation to support 'best practice' (DOM ids 'off' by default, 'o= n' > > explicitly, to avoid 'duplicate ids by accident'). Maybe some sort of > > import wizard for a legacy flex project could do something like this in > an > > IDE by default though. But it could be a compiler config thing too > perhaps." > > > > Does your idea is saying that if I have some Flex app or even write som= e > on > > my own setting that option to ON - change the way how things are > > outputting after compilation ? Do you mean that: > > > >