Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix remaining typechecks in gmf #4606

Merged
merged 3 commits into from Feb 7, 2019

Conversation

adube
Copy link
Contributor

@adube adube commented Feb 6, 2019

This patch fixes the remaining type issues in GMF.

Following @fredj recommendation, I copied the properties from ("ngeo/datasource/OGC.js").OGCOptions to ("gmf/datasource/OGC.js").OGCOptions, because typescript doesn't currently support inheritence of objects for typing purpose.

There are also 2 remaining errors that I don't know what to do about. They are about the use of DocumentTouch property, which seems to be deprecated. I suspect this is something that needs to be addressed (and not just ignored using ts-ignore). Here they are:

contribs/gmf/src/controllers/bootstrap.js:24:65 - error TS2339: Property 'DocumentTouch' does not exist on type 'never'.

24       if (small_screen && (('ontouchstart' in window) || window.DocumentTouch && document instanceof DocumentTouch)) {
                                                                   ~~~~~~~~~~~~~

contribs/gmf/src/controllers/bootstrap.js:24:102 - error TS2304: Cannot find name 'DocumentTouch'.

24       if (small_screen && (('ontouchstart' in window) || window.DocumentTouch && document instanceof DocumentTouch)) {
         

@adube adube requested review from fredj and sbrunner February 6, 2019 16:54
@adube adube force-pushed the fix-types-gmf-complete branch 3 times, most recently from baf6df1 to fc8e3ca Compare February 6, 2019 18:39
@fredj
Copy link
Member

fredj commented Feb 7, 2019

See #4609 for the DocumentTouch warning

@adube
Copy link
Contributor Author

adube commented Feb 7, 2019

All done. Ready merge?

Copy link
Member

@sbrunner sbrunner left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Merge when Travis is OK :-)

@adube adube merged commit bae323e into camptocamp:master Feb 7, 2019
@adube adube deleted the fix-types-gmf-complete branch February 7, 2019 18:25
@sbrunner sbrunner added this to the 2.4 milestone Feb 28, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants