NativeScript / NativeScript/ios

[BUG] - Problem on modal - Error: Attempted to assign to readonly property.

Open
#53 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
150
Forks
43
Avg merge
3d 10h
Merged PRs (30d)
22

Description

Hi guys,
because I need to enable Bitcode I've adopted new runtime and I succeeded to enable it.
With new runtime I have some crashes and issues.

If I open a modal I have this log and modals do not open:

CONSOLE ERROR: ERROR Error: Uncaught (in promise): Error: Attempted to assign to readonly property.
Error: Attempted to assign to readonly property.
at GridLayout.push.../node_modules/@nativescript/core/ui/core/view/view.js.View._showNativeModalView (file: node_modules/@nativescript/core/ui/core/view/view.ios.js:370:0)
at ProxyViewContainer.push.../node_modules/@nativescript/core/ui/core/view/view-common.js.ViewCommon.showModal (file: node_modules/@nativescript/core/ui/core/view/view-common.js:283:0)
at file: node_modules/@nativescript/angular/directives/dialogs.js:99:0
at ZoneDelegate.push.../node_modules/@nativescript/angular/zone-js/dist/zone-nativescript.js.ZoneDelegate.invoke (file: node_modules/@nativescript/angular/zone-js/dist/zone-nativescript.js:388:0)
at Object.onInvoke (file: node_modules/@angular/core/fesm5/core.js:26256:0)
at ZoneDelegate.push.../node_modules/@nativescript/angular/zone-js/dist/zone-nativescript.js.ZoneDelegate.invoke (file: node_modules/@nativescript/angular/zone-js/dist/zone-nativescript.js:387:0)
at Zone.push.../node_modules/@nativescript/angular/zone-js/dist/zone-nativescript.js.Zone.run (file: node_modules/@nativescript/angular/zone-js/dist/zone-nativescript.js:138:0)
at file: node_modules/@nativescript/angular/zone-js/dist/zone-nativescript.js:883:0
at ZoneDele<…>

Problem is on these line:

controller.animated = animated;

Thanks for your help and support.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with node_modules/@nativescript/core/ui/core/view/view.ios.js at line 370, then trace the modal call through view-common.js:283 and @nativescript/angular/directives/dialogs.js:99. Reproduce the modal failure with the new runtime and Bitcode enabled, and confirm that modals open without the readonly-property error.

Written by the indexing model from the issue text.

Assessment

Tech stack
ios, javascript
Domain
mobile-dev
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.