-
Notifications
You must be signed in to change notification settings - Fork 98
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
perf: move out non-reused components #4051
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Regarding commit history, it would be better to have a BREAKING CHANGE commit but I agree that it doesn't make sense for other modules than cloud-universe-components
@@ -8,11 +8,13 @@ import '@ovh-ux/ng-ovh-doc-url'; | |||
import { Environment } from '@ovh-ux/manager-config'; | |||
|
|||
import logs from './logs'; | |||
import cuiDualList from './components/dual-list'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm wondering if we can replace all those cui
components by ovh-ui-kit
ones as a next step
angular.module(moduleName, [ | ||
cucConsumption, | ||
cucCurrency, | ||
cucFlavor, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If I have a look this is only used for one function of one service across all manager, maybe we can just replace its usage
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i just deleted cucFlavor module and copied the "addOverQuotasInfos" where it's used (in kubernetes node-pool nodes add)
import cucNavigation from './navigation'; | ||
import cucOrderedHash from './orderedHash'; | ||
import cucPoll from './poll'; | ||
import cucPrice from './price'; | ||
import cucRegion from './region'; | ||
import cucProducts from './products'; | ||
import cucSmoothScrollHere from './smoothScrollHere'; | ||
import cucSpaceMeter from './space-meter'; | ||
import cucSshKeyMin from './sshKeyMin'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks like there is the same filter in the dedicated app. We have moved it to dedicated universe components.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes but it's also used in cloud app, how did you handle the case ?
(https://github.com/ovh/manager/blob/master/packages/manager/apps/cloud/client/app/cloud/project/compute/ssh/cloud-project-compute-ssh.html#L331)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I moved it to dedicated universe componets. We need to revisit to consolidate this.
7b9307d
to
ef54f74
Compare
Hey @frenautvh there is some conflicts (maybe related with #4306) |
985b5ea
985b5ea
to
13c136f
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Well done!
Only noticed two translations files that can be removed.
packages/manager/modules/nasha/src/components/space-meter/translations/Messages_lt_LT.json
Outdated
Show resolved
Hide resolved
packages/manager/modules/nasha/src/components/space-meter/translations/Messages_fi_FI.json
Outdated
Show resolved
Hide resolved
Signed-off-by: frenauvh <[email protected]>
13c136f
to
6d0f640
Compare
Description
Some modules in cloud-universe-components are used only once. Move them out to the corresponding app or module directly. This helps to avoid bundling unnecessary components.
(for example d3 has been removed from cloud-universe-components and won't be bundled anymore on manager dedicated app)
Note regarding adding breaking change or not to the commit :
I think it's debatable since cloud-universe-components is a private package, semver is basically ignored because at each build the last version will be used. Making the commit a breaking change would also major bump some apps & modules which i think is not what we want (and splitting in 2 commits seems difficult since files are moved and not created/deleted). Please share your point of view if you disagree thanks