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

chore: Adding scheduler as a peer dependency of packages using @fluentui/react-context-selector #23681

Merged
merged 5 commits into from
Jun 23, 2022

Conversation

khmakoto
Copy link
Member

PR Description

#21769 moved the scheduler dependency in @fluentui/react-context-selector to be a peer dependency instead. However, packages using @fluentui/react-context-selector did not have this dependency added to them, which causes problems in some build systems using these packages as it is marked as a missing dependency, even if explicitly added there.

This PR fixes the issue by adding scheduler as a peer dependency of those packages that use @fluentui/react-context-selector. It also orders some of the dependencies in those packages alphabetically.

Related Issue(s)

Fixes #23639

@khmakoto khmakoto self-assigned this Jun 22, 2022
@github-actions github-actions bot added this to the June Project Cycle Q2 2022 milestone Jun 22, 2022
@codesandbox-ci
Copy link

codesandbox-ci bot commented Jun 22, 2022

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

Latest deployment of this branch, based on commit b1d9bc7:

Sandbox Source
@fluentui/react 8 starter Configuration
@fluentui/react-components 9 starter Configuration

@fabricteam
Copy link
Collaborator

fabricteam commented Jun 22, 2022

📊 Bundle size report

Unchanged fixtures
Package & Exports Size (minified/GZIP)
global-context
createContext
533 B
341 B
global-context
createContextSelector
554 B
348 B
priority-overflow
createOverflowManager
2.936 kB
1.212 kB
react-accordion
Accordion (including children components)
76.07 kB
23.149 kB
react-avatar
Avatar
46.757 kB
13.737 kB
react-badge
Badge
21.653 kB
6.862 kB
react-badge
CounterBadge
22.557 kB
7.172 kB
react-badge
PresenceBadge
23.357 kB
7.099 kB
react-button
Button
35.704 kB
9.499 kB
react-button
CompoundButton
42.777 kB
10.733 kB
react-button
MenuButton
38.279 kB
10.365 kB
react-button
SplitButton
45.612 kB
11.71 kB
react-button
ToggleButton
50.929 kB
10.919 kB
react-card
Card - All
66.861 kB
18.981 kB
react-card
Card
62.017 kB
17.849 kB
react-card
CardFooter
8.461 kB
3.555 kB
react-card
CardHeader
10.026 kB
4.067 kB
react-card
CardPreview
8.562 kB
3.61 kB
react-combobox
Combobox
62.291 kB
21.341 kB
react-components
react-components: Accordion, Button, FluentProvider, Image, Menu, Popover
187.299 kB
51.651 kB
react-components
react-components: FluentProvider & webLightTheme
31.883 kB
10.516 kB
react-divider
Divider
16.321 kB
5.837 kB
react-image
Image
10.68 kB
4.215 kB
react-input
Input
22.861 kB
7.512 kB
react-label
Label
9.238 kB
3.815 kB
react-link
Link
12.082 kB
4.88 kB
react-menu
Menu (including children components)
114.804 kB
34.885 kB
react-menu
Menu (including selectable components)
117.979 kB
35.372 kB
react-overflow
hooks only
10.839 kB
4.146 kB
react-popover
Popover
104.777 kB
31.889 kB
react-portal
Portal
10.033 kB
3.753 kB
react-positioning
usePositioning
23.839 kB
8.292 kB
react-provider
FluentProvider
14.76 kB
5.596 kB
react-radio
Radio
30.438 kB
10.41 kB
react-radio
RadioGroup
14.319 kB
5.711 kB
react-select
Select
20.002 kB
7.171 kB
react-slider
Slider
26.136 kB
8.387 kB
react-spinbutton
SpinButton
43.35 kB
12.273 kB
react-spinner
Spinner
19.073 kB
6.308 kB
react-switch
Switch
26.58 kB
8.602 kB
react-text
Text - Default
11.572 kB
4.537 kB
react-text
Text - Wrappers
14.882 kB
4.977 kB
react-textarea
Textarea
22.228 kB
7.523 kB
react-theme
Single theme token import
69 B
89 B
react-theme
Teams: all themes
28.995 kB
6.215 kB
react-theme
Teams: Light theme
16.973 kB
4.86 kB
react-tooltip
Tooltip
44.55 kB
15.386 kB
react-utilities
SSRProvider
189 B
161 B
🤖 This report was generated against 52f6f9da2687560b5f165309c6c54c63878379f8

@@ -28,22 +28,22 @@
"@fluentui/eslint-plugin": "*",
"@fluentui/react-conformance": "*",
"@fluentui/react-conformance-griffel": "9.0.0-beta.8",
"@fluentui/react-context-selector": "9.0.0-rc.10",
Copy link
Contributor

Choose a reason for hiding this comment

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

is react-context-selector being removed fully here?

Copy link
Contributor

Choose a reason for hiding this comment

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

oh it was in devDeps and deps

Copy link
Member Author

Choose a reason for hiding this comment

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

No, the dependency was, for whatever reason, added twice here, once in devDependencies and once in dependencies. I'm simply removing the one in devDependencies to avoid unnecessary duplication.

@fabricteam
Copy link
Collaborator

fabricteam commented Jun 22, 2022

Perf Analysis (@fluentui/react-components)

No significant results to display.

All results

Scenario Render type Master Ticks PR Ticks Iterations Status
Avatar mount 1656 1655 5000
Button mount 1239 1259 5000
FluentProvider mount 2256 2216 5000
FluentProviderWithTheme mount 892 913 10
FluentProviderWithTheme virtual-rerender 894 855 10
FluentProviderWithTheme virtual-rerender-with-unmount 899 932 10
MakeStyles mount 2420 2425 50000

@size-auditor
Copy link

size-auditor bot commented Jun 22, 2022

Asset size changes

Size Auditor did not detect a change in bundle size for any component!

Baseline commit: 52f6f9da2687560b5f165309c6c54c63878379f8 (build)

@ling1726
Copy link
Member

In this case, shouldn't react-components also have a peer dependency on scheduler ?

@khmakoto khmakoto requested review from a team as code owners June 23, 2022 19:57
@fabricteam
Copy link
Collaborator

fabricteam commented Jun 23, 2022

Perf Analysis (@fluentui/react-northstar)

Perf tests with no regressions
Scenario Current PR Ticks Baseline Ticks Ratio
DropdownManyItemsPerf.default 804 749 1.07:1
AnimationMinimalPerf.default 599 567 1.06:1
FlexMinimalPerf.default 300 284 1.06:1
InputMinimalPerf.default 1419 1342 1.06:1
HeaderMinimalPerf.default 402 383 1.05:1
CarouselMinimalPerf.default 519 498 1.04:1
ListMinimalPerf.default 570 546 1.04:1
ListNestedPerf.default 611 590 1.04:1
ProviderMinimalPerf.default 410 393 1.04:1
RefMinimalPerf.default 242 232 1.04:1
SegmentMinimalPerf.default 374 360 1.04:1
SkeletonMinimalPerf.default 373 359 1.04:1
TreeWith60ListItems.default 181 174 1.04:1
ButtonMinimalPerf.default 186 181 1.03:1
ItemLayoutMinimalPerf.default 1318 1283 1.03:1
PortalMinimalPerf.default 162 157 1.03:1
TreeMinimalPerf.default 908 885 1.03:1
DropdownMinimalPerf.default 3293 3227 1.02:1
LayoutMinimalPerf.default 379 370 1.02:1
ReactionMinimalPerf.default 409 400 1.02:1
SliderMinimalPerf.default 1856 1822 1.02:1
TableManyItemsPerf.default 2183 2146 1.02:1
TextMinimalPerf.default 379 372 1.02:1
TextAreaMinimalPerf.default 553 540 1.02:1
AttachmentSlotsPerf.default 1199 1193 1.01:1
ButtonSlotsPerf.default 582 578 1.01:1
ChatMinimalPerf.default 802 796 1.01:1
CheckboxMinimalPerf.default 2818 2792 1.01:1
DatepickerMinimalPerf.default 6004 5965 1.01:1
HeaderSlotsPerf.default 830 824 1.01:1
ListWith60ListItems.default 685 679 1.01:1
RosterPerf.default 1269 1262 1.01:1
PopupMinimalPerf.default 652 643 1.01:1
RadioGroupMinimalPerf.default 483 479 1.01:1
StatusMinimalPerf.default 728 724 1.01:1
IconMinimalPerf.default 674 668 1.01:1
CustomToolbarPrototype.default 2940 2917 1.01:1
ToolbarMinimalPerf.default 1064 1056 1.01:1
AlertMinimalPerf.default 297 297 1:1
AvatarMinimalPerf.default 204 204 1:1
ChatDuplicateMessagesPerf.default 288 287 1:1
DialogMinimalPerf.default 814 817 1:1
EmbedMinimalPerf.default 4368 4370 1:1
LabelMinimalPerf.default 399 399 1:1
MenuButtonMinimalPerf.default 1833 1833 1:1
ProviderMergeThemesPerf.default 1233 1235 1:1
SplitButtonMinimalPerf.default 4735 4744 1:1
TooltipMinimalPerf.default 1299 1296 1:1
VideoMinimalPerf.default 718 719 1:1
AccordionMinimalPerf.default 154 155 0.99:1
AttachmentMinimalPerf.default 154 156 0.99:1
BoxMinimalPerf.default 357 362 0.99:1
ButtonOverridesMissPerf.default 1601 1613 0.99:1
MenuMinimalPerf.default 891 896 0.99:1
FormMinimalPerf.default 447 457 0.98:1
ImageMinimalPerf.default 398 407 0.98:1
ListCommonPerf.default 707 722 0.98:1
CardMinimalPerf.default 600 619 0.97:1
ChatWithPopoverPerf.default 409 420 0.97:1
LoaderMinimalPerf.default 733 765 0.96:1
TableMinimalPerf.default 417 433 0.96:1
DividerMinimalPerf.default 362 384 0.94:1
GridMinimalPerf.default 360 388 0.93:1

@fabricteam
Copy link
Collaborator

fabricteam commented Jun 23, 2022

Perf Analysis (@fluentui/react)

No significant results to display.

All results

Scenario Render type Master Ticks PR Ticks Iterations Status
BaseButton mount 1090 1103 5000
Breadcrumb mount 2924 3155 1000
Checkbox mount 1684 1612 5000
CheckboxBase mount 1497 1488 5000
ChoiceGroup mount 5401 5465 5000
ComboBox mount 1079 1104 1000
CommandBar mount 11997 12083 1000
ContextualMenu mount 11939 12340 1000
DefaultButton mount 1314 1289 5000
DetailsRow mount 4136 4259 5000
DetailsRowFast mount 4286 4218 5000
DetailsRowNoStyles mount 3871 3804 5000
Dialog mount 3145 3099 1000
DocumentCardTitle mount 203 202 1000
Dropdown mount 3830 3800 5000
FocusTrapZone mount 2074 2129 5000
FocusZone mount 1994 1942 5000
IconButton mount 1991 2017 5000
Label mount 373 392 5000
Layer mount 3351 3318 5000
Link mount 524 532 5000
MenuButton mount 1727 1706 5000
MessageBar mount 2258 2376 5000
Nav mount 3777 3637 1000
OverflowSet mount 1209 1217 5000
Panel mount 2397 2395 1000
Persona mount 1170 1175 1000
Pivot mount 1546 1635 1000
PrimaryButton mount 1454 1489 5000
Rating mount 9017 8926 5000
SearchBox mount 1568 1540 5000
Shimmer mount 2735 2852 5000
Slider mount 2056 2044 5000
SpinButton mount 5694 5569 5000
Spinner mount 502 475 5000
SplitButton mount 3632 3581 5000
Stack mount 618 630 5000
StackWithIntrinsicChildren mount 2754 2743 5000
StackWithTextChildren mount 6118 6210 5000
SwatchColorPicker mount 13309 12933 5000
TagPicker mount 2949 3091 5000
TeachingBubble mount 111130 100158 5000
Text mount 501 534 5000
TextField mount 1604 1679 5000
ThemeProvider mount 1335 1362 5000
ThemeProvider virtual-rerender 720 719 5000
ThemeProvider virtual-rerender-with-unmount 2060 2133 5000
Toggle mount 911 877 5000
buttonNative mount 140 142 5000

@khmakoto khmakoto enabled auto-merge (squash) June 23, 2022 20:27
@khmakoto khmakoto merged commit ddf16d8 into microsoft:master Jun 23, 2022
@khmakoto khmakoto deleted the schedulerDep branch June 23, 2022 21:05
rohitpagariya pushed a commit to rohitpagariya/fluentui that referenced this pull request Jun 28, 2022
…tui/react-context-selector (microsoft#23681)

* Adding scheduler as a peer dependency of packages using @fluentui/react-context-selector.

* Removing new line.

* Adding change files.

* Adding change file.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Development

Successfully merging this pull request may close these issues.

[Bug]: Missing scheduler dependency in react-component packages
8 participants