PeterStaev / NativeScript-Drop-Down

A NativeScript DropDown widget.
Apache License 2.0
105 stars 65 forks source link

Import wrong module on Nativescript 3.x #128

Closed phattranky closed 6 years ago

phattranky commented 7 years ago

I used the latest version of nativescript-drop-down. Then I have an issue while compile. Please see the picture

screen shot 2017-08-22 at 9 38 15 pm

Then I modify the file drop-down.d.ts by add the tns-core-modules before data, ui. It's working well

import { ObservableArray } from "tns-core-modules/data/observable-array";
import { CoercibleProperty, Property, View } from "ui/core/view";
import { EventData } from "tns-core-modules/data/observable";
import { ItemsSource } from "tns-core-modules/ui/list-picker";

Please add this changes to new Pull Request, Thanks

PeterStaev commented 7 years ago

Hey @phattranky , make sure you have tns-core-modules added to the path of your tsconfig file like it is in the demo: https://github.com/PeterStaev/NativeScript-Drop-Down/blob/master/demo-ng/tsconfig.json#L15 . This is part of the NS 3.0 migration guide here.

PeterStaev commented 6 years ago

No further response so closing this one for now. In case you still have problems, please provide more details.