RadSideDrawer cause app crash at runtime after NS 3.0.3 update


#1

hi guys… …I finished an ios app some months back, in which I used the RadSideDrawer. Everything was working fine. Today, I updated the nativescript version and every single node module in the project. after a successful build, when I try to start the app, I get this error in the home view:

JS ERROR Error: Building UI from XML. @file:///app/views/home/home.xml:6:5 
 > Module '/Users/mee/Library/Developer/CoreSimulator/Devices/71FD5130-5C4A-4A6A-A3C1-837C266A2744/data/Containers/Bundle/Application/EBD51908-655D-473C-98E1-CF8FBC6F7DFD/myappname.app/app/nativescript-telerik-ui/sidedrawer' not found for element 'nativescript-telerik-ui/sidedrawer:RadSideDrawer'.

 > Could not find module '/Users/mee/Library/Developer/CoreSimulator/Devices/71FD5130-5C4A-4A6A-A3C1-837C266A2744/data/Containers/Bundle/Application/EBD51908-655D-473C-98E1-CF8FBC6F7DFD/myappname.app/app/nativescript-telerik-ui/sidedrawer'. Computed path '/Users/mee/Library/Developer/CoreSimulator/Devices/71FD5130-5C4A-4A6A-A3C1-837C266A2744/data/Containers/Bundle/Application/EBD51908-655D-473C-98E1-CF8FBC6F7DFD/myappname.app/app/nativescript-telerik-ui/sidedrawer'

…then the app crashes. Apparently this issue had been solved some time ago: https://groups.google.com/forum/#!topic/nativescript/ovDzPNlXQ9I …but none of the suggestions there works again. plus, there isn’t a “lib” folder to delete anymore. I have done “tns platform remove ios” and even “…clean”, all to no avail.

It’s a typescript (without angular) project.

I’d apprecaite any help. thanks.


#2

Hey,

This looks like a problem with TypeScript not being able to find the necessary TypeScript definition files. Since this is an upgrade to 3.0, make sure you make the necessary TypeScript configuration changes at https://github.com/NativeScript/NativeScript/blob/master/Modules30Changes.md#typescript.

It’s probably easiest to copy and paste the tsconfig.json from an existing project, for example https://github.com/NativeScript/sample-Groceries/blob/master/tsconfig.json.

Also make sure that your package.json is including a devDependency of "typescript" that is at least version 2.2.0, for example https://github.com/NativeScript/sample-Groceries/blob/9c6771486362e91e4991f126fa45f58d1db66376/package.json#L55.

If that doesn’t work let me know and we’ll see where we can go from here.


#3

Thanks TJ for the reply. I effected these changes, removed and added ios, but I still got the error.
“Marek” on Slack, suggested I change my xml markup from:

  xmlns:drawer="nativescript-telerik-ui/sidedrawer"```

to

```xmlns:dpg="tns_modules/nativescript-telerik-ui/sidedrawer/drawerpage" 
  xmlns:drawer="tns_modules/nativescript-telerik-ui/sidedrawer">```.

I did and it worked! the error went away! :smile:
The app still carshes tho, with

 ```...Service exited due to signal: Killed: 9```  

I tried suggestions from https://github.com/NativeScript/nativescript-angular/issues/101, to no avail.
I now wish I hadn't updated in the 1st place.
:confused: