Hi Piotr,

I still don't think the compiler can tell if you will be using an id more
than once.  At least not with a lot of flow analysis and even then I think
we'd miss cases.

You should be able to use the same id more than once.  You might be
removing the first view and replacing it with a different view and both
might have the same id.

IMO, the only warning must be done at runtime.  Feel free to create a
DuplicateIDCheckingBead that does that work.  I think it would replace the
UIBase id setter with a version that calls getElementById on the proposed
id.

My 2 cents,
-Alex

On 7/17/17, 3:20 AM, "piotrz" <piotrzarzyck...@gmail.com> wrote:

>Hi Alex,
>
>That's a valid point and I think I'm willing to change my vote to have
>localId. Let me understand fully this. If we introduce "localId" -
>
>- We will be able to have same id in different view - Introducing that new
>field is less time consuming than doing solution which I vote for ?
>- Compiler will shot us some warning if we have duplicate "id" ?
>
>Thanks,
>Piotr
>
>
>
>
>
>-----
>Apache Flex PMC
>piotrzarzyck...@gmail.com
>--
>View this message in context:
>https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fapache-fle
>x-development.2333347.n4.nabble.com%2FFlexJS-MXML-ids-and-classNames-tp543
>61p63328.html&data=02%7C01%7C%7C8772b947ed204967a34408d4cd002f3c%7Cfa7b1b5
>a7b34438794aed2c178decee1%7C0%7C0%7C636358848070298436&sdata=18lcB0kmjhL1q
>64dKeWha7%2B96F%2F%2BtECazuFZ2X2F5AM%3D&reserved=0
>Sent from the Apache Flex Development mailing list archive at Nabble.com.

Reply via email to