Titanium JIRA Archive
Alloy (ALOY)

[ALOY-863] Mobileweb 3.2.0 breaks Alloy apps with "'apiName' is read only"

GitHub Issuen/a
TypeBug
PriorityCritical
StatusClosed
ResolutionFixed
Resolution Date2013-10-26T03:09:49.000+0000
Affected Version/sn/a
Fix Version/sAlloy 1.3.0, 2013 Sprint 22
ComponentsRuntime
Labelsn/a
ReporterTony Lukasavage
AssigneeTony Lukasavage
Created2013-10-25T21:05:50.000+0000
Updated2013-12-10T00:38:14.000+0000

Description

problem

To facilitate dynamic styling to this point, Alloy was required to shim the non-existent "apiName" property on Titanium proxies in order to automatically apply appropriate styles. In TiSDK 3.2.0+ this property has been implemented natively. It works fine in Android and iOS, but unfortunately in Mobileweb it has been explicitly implemented (not just documented) as a readonly property, I'm assuming via:
Object.defineProperty(proxy, "apiName", {writable:false});
This unfortunately causes an unavoidable runtime error in any Alloy app that would make use of dynamic styling, and perhaps even some that don't.

error

See attached screenshot

test case

Run the following test app for alloy for mobileweb and you will get this error: https://github.com/appcelerator/alloy/tree/master/test/apps/advanced/require_children

Attachments

FileDateSize
Screen Shot 2013-10-25 at 5.04.19 PM.png2013-10-25T21:09:26.000+000024159

Comments

  1. Tony Lukasavage 2013-10-26

    PR: https://github.com/appcelerator/alloy/pull/260 test app: https://github.com/appcelerator/alloy/tree/master/test/apps/advanced/require_children Run the test app for Mobileweb using TiSDK 3.2.0+ and ensure that it runs as expected with no runtime errors. Be sure to ignored the undefined values returned from the button clicks as this is a result of TIMOB-13816.
  2. Federico Casali 2013-12-10

    Verified fixed. TiSDK 3.2.0.v20131209000852 CLI 3.2.0-beta Alloy 1.3.0-beta Titanium Studio 3.2.0.201312081251 Closing.

JSON Source