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 warnings during the "Bundling to UMD" #54

Merged
merged 2 commits into from
Mar 31, 2020
Merged

Conversation

flavens
Copy link
Collaborator

@flavens flavens commented Mar 31, 2020

It resolves the following warnings during the project build:
Screenshot 2020-03-26 at 09 43 08

closes #49

YouTrack issue: https://dasch.myjetbrains.com/youtrack/issue/DSP-51

@flavens flavens self-assigned this Mar 31, 2020
"ngx-color-picker": "ngxColorPicker",
"jdnconvertiblecalendar": "jdnconvertiblecalendar",
"jdnconvertiblecalendardateadapter": "jdnconvertiblecalendardateadapter",
"jdnconvertiblecalendar/dist/src/JDNConvertibleCalendar": "JDNConvertibleCalendar"
Copy link
Contributor

Choose a reason for hiding this comment

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

I wonder why there is jdnconvertiblecalendar and JDNConvertibleCalendar. jdnconvertiblecalendar/dist/src/JDNConvertibleCalendar seems odd. Maybe I did something wrong in https://github.com/dhlab-basel/JDNConvertibleCalendar, I will check this.

@tobiasschweizer
Copy link
Contributor

I found the problem:

https://github.com/dasch-swiss/knora-ui-ng-lib/blob/373e762ac7dcab0f8c9894fde830c749aba96ca7/projects/knora-ui/src/lib/viewer/values/time-value/time-input/time-input.component.ts#L7-L9

The imports have to be changed to (JDNConvertibleCalendarModule is not needed):

import {CalendarDate, CalendarPeriod, GregorianCalendarDate} from 'jdnconvertiblecalendar';

and then

https://github.com/dasch-swiss/knora-ui-ng-lib/blob/6d211c58da73c7c4eb8695a0c6c68fc2fca1bb62/projects/knora-ui/ng-package.json#L11

becomes obsolete.

@tobiasschweizer
Copy link
Contributor

I wonder if we have to do something about

WARNING: 'ReadValue', 'ReadTextValueAsString', 'ReadIntValue', 'ReadLinkValue', 'ReadBooleanValue', 'ReadDecimalValue', 'ReadColorValue', 'ReadUriValue', 'ReadIntervalValue' and 'ReadTimeValue' are imported from external module '@knora/api' but never used

I found angular/angular#21280 which you have already mentioned :-)

Copy link
Contributor

@tobiasschweizer tobiasschweizer left a comment

Choose a reason for hiding this comment

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

Looks good, thanks!

@flavens
Copy link
Collaborator Author

flavens commented Mar 31, 2020

I found angular/angular#21280 which you have already mentioned :-)

I tried the solution with emitDecoratorMetadata sets to true but it did not change anything...

@tobiasschweizer
Copy link
Contributor

tobiasschweizer commented Mar 31, 2020

I found angular/angular#21280 which you have already mentioned :-)

I tried the solution with emitDecoratorMetadata sets to true but it did not change anything...

I think it's not a real problem.

@tobiasschweizer
Copy link
Contributor

probably it's just some imports that are still in the JavaScript code that's generated from the TypeScript source, but in JavaScript these classes are not used since the refer to TypeScript constructs

@tobiasschweizer
Copy link
Contributor

so this PR is good to go :-)

@flavens flavens merged commit 51138c5 into master Mar 31, 2020
@flavens flavens deleted the fix/49-umd-warnings branch March 31, 2020 15:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Fix WARNING: No name was provided for external module "xxx" in output.globals – guessing "xxx"
2 participants