Skip to content

Drop ts-loader in favor of swc-loader for Stress Test app#25179

Merged
spmonahan merged 1 commit into
microsoft:masterfrom
spmonahan:stress-test/multiple-ts-loaders
Oct 14, 2022
Merged

Drop ts-loader in favor of swc-loader for Stress Test app#25179
spmonahan merged 1 commit into
microsoft:masterfrom
spmonahan:stress-test/multiple-ts-loaders

Conversation

@spmonahan

@spmonahan spmonahan commented Oct 11, 2022

Copy link
Copy Markdown
Contributor

Current Behavior

We use different Typescript loaders in Webpack for React and Web Components

New Behavior

We use the same loader (swc-loader) for all code. This simplifies the Webpack config and speeds up builds.

Validation Steps

  1. Pull branch
  2. yarn
  3. yarn workspace @fluentui/stress-test stress-test build
  4. yarn workspace @fluentui/stress-test stress-test serve
  5. Open http://localhost:8080/wc/simple-stress and http://localhost:8080/v9/simple-stress successfully in your browser of choice

Related Issue(s)

Fixes #24306

@codesandbox-ci

codesandbox-ci Bot commented Oct 12, 2022

Copy link
Copy Markdown

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 989081c:

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

@size-auditor

size-auditor Bot commented Oct 12, 2022

Copy link
Copy Markdown

Asset size changes

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

Baseline commit: 82650ef8b3d436c039e33f3eb8a658a3d878064f (build)

@fabricteam

fabricteam commented Oct 12, 2022

Copy link
Copy Markdown
Collaborator

Perf Analysis (@fluentui/react-components)

No significant results to display.

All results

Scenario Render type Master Ticks PR Ticks Iterations Status
Avatar mount 1558 1559 5000
Button mount 1110 1103 5000
FluentProvider mount 1857 1807 5000
FluentProviderWithTheme mount 736 741 10
FluentProviderWithTheme virtual-rerender 698 688 10
FluentProviderWithTheme virtual-rerender-with-unmount 753 761 10
MakeStyles mount 2199 2258 50000
SpinButton mount 2971 2924 5000

@fabricteam

fabricteam commented Oct 12, 2022

Copy link
Copy Markdown
Collaborator

📊 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
3.153 kB
1.299 kB
react-accordion
Accordion (including children components)
79.083 kB
24.079 kB
react-alert
Alert
84.575 kB
21.195 kB
react-avatar
Avatar
48.874 kB
13.864 kB
react-avatar
AvatarGroup
14.996 kB
6.013 kB
react-avatar
AvatarGroupItem
68.842 kB
19.205 kB
react-badge
Badge
22.646 kB
7.228 kB
react-badge
CounterBadge
23.536 kB
7.512 kB
react-badge
PresenceBadge
24.096 kB
7.09 kB
react-button
Button
36.736 kB
9.845 kB
react-button
CompoundButton
43.761 kB
11.061 kB
react-button
MenuButton
39.43 kB
10.745 kB
react-button
SplitButton
46.876 kB
12.129 kB
react-button
ToggleButton
52.603 kB
11.317 kB
react-card
Card - All
67.216 kB
19.304 kB
react-card
Card
62.898 kB
18.22 kB
react-card
CardFooter
8.607 kB
3.622 kB
react-card
CardHeader
9.65 kB
3.962 kB
react-card
CardPreview
8.708 kB
3.678 kB
react-combobox
Combobox (including child components)
75.141 kB
24.428 kB
react-combobox
Dropdown (including child components)
74.869 kB
24.385 kB
react-components
react-components: Button, FluentProvider & webLightTheme
62.827 kB
17.599 kB
react-components
react-components: Accordion, Button, FluentProvider, Image, Menu, Popover
189.375 kB
52.561 kB
react-components
react-components: FluentProvider & webLightTheme
33.446 kB
11.033 kB
react-dialog
Dialog (including children components)
82.626 kB
24.504 kB
react-divider
Divider
16.505 kB
5.925 kB
react-image
Image
10.826 kB
4.286 kB
react-infobutton
InfoButton
7.742 kB
3.265 kB
react-input
Input
23.808 kB
7.729 kB
react-label
Label
9.384 kB
3.883 kB
react-link
Link
11.852 kB
4.888 kB
react-menu
Menu (including children components)
116.668 kB
35.792 kB
react-menu
Menu (including selectable components)
119.737 kB
36.316 kB
react-overflow
hooks only
11.004 kB
4.188 kB
react-persona
Persona
53.992 kB
15.25 kB
react-popover
Popover
102.864 kB
31.542 kB
react-portal
Portal
10.628 kB
3.899 kB
react-portal-compat
PortalCompatProvider
5.857 kB
1.978 kB
react-positioning
usePositioning
19.724 kB
7.415 kB
react-progress
Progress
11.66 kB
4.619 kB
react-provider
FluentProvider
15.807 kB
5.909 kB
react-radio
Radio
36.436 kB
12.126 kB
react-radio
RadioGroup
14.294 kB
5.723 kB
react-select
Select
20.892 kB
7.367 kB
react-slider
Slider
31.805 kB
10.085 kB
react-spinbutton
SpinButton
44.228 kB
12.454 kB
react-spinner
Spinner
20.023 kB
6.461 kB
react-switch
Switch
33.388 kB
10.578 kB
react-text
Text - Default
11.828 kB
4.627 kB
react-text
Text - Wrappers
15.138 kB
5.064 kB
react-textarea
Textarea
25.064 kB
8.158 kB
react-theme
Single theme token import
69 B
89 B
react-theme
Teams: all themes
29.65 kB
6.444 kB
react-theme
Teams: Light theme
17.486 kB
5.057 kB
react-tooltip
Tooltip
41.718 kB
14.687 kB
react-utilities
SSRProvider
180 B
159 B
🤖 This report was generated against 82650ef8b3d436c039e33f3eb8a658a3d878064f

@fabricteam

fabricteam commented Oct 12, 2022

Copy link
Copy Markdown
Collaborator

Perf Analysis (@fluentui/react-northstar)

Perf tests with no regressions
Scenario Current PR Ticks Baseline Ticks Ratio
CardMinimalPerf.default 453 422 1.07:1
ReactionMinimalPerf.default 319 300 1.06:1
DividerMinimalPerf.default 299 285 1.05:1
LabelMinimalPerf.default 320 306 1.05:1
PortalMinimalPerf.default 146 139 1.05:1
VideoMinimalPerf.default 622 591 1.05:1
ChatMinimalPerf.default 614 588 1.04:1
LayoutMinimalPerf.default 300 288 1.04:1
SkeletonMinimalPerf.default 287 276 1.04:1
StatusMinimalPerf.default 559 536 1.04:1
ButtonOverridesMissPerf.default 1105 1077 1.03:1
CarouselMinimalPerf.default 382 371 1.03:1
TextMinimalPerf.default 289 281 1.03:1
AnimationMinimalPerf.default 447 437 1.02:1
ButtonSlotsPerf.default 463 453 1.02:1
FormMinimalPerf.default 310 305 1.02:1
SliderMinimalPerf.default 1335 1310 1.02:1
TextAreaMinimalPerf.default 387 378 1.02:1
TreeMinimalPerf.default 670 658 1.02:1
AttachmentMinimalPerf.default 118 117 1.01:1
AvatarMinimalPerf.default 157 156 1.01:1
DropdownMinimalPerf.default 2266 2247 1.01:1
EmbedMinimalPerf.default 3053 3016 1.01:1
FlexMinimalPerf.default 231 228 1.01:1
GridMinimalPerf.default 280 278 1.01:1
HeaderSlotsPerf.default 639 632 1.01:1
ImageMinimalPerf.default 311 308 1.01:1
InputMinimalPerf.default 948 941 1.01:1
ItemLayoutMinimalPerf.default 965 952 1.01:1
ListMinimalPerf.default 427 421 1.01:1
LoaderMinimalPerf.default 544 540 1.01:1
MenuButtonMinimalPerf.default 1410 1401 1.01:1
ProviderMergeThemesPerf.default 1063 1050 1.01:1
ProviderMinimalPerf.default 334 331 1.01:1
SegmentMinimalPerf.default 287 285 1.01:1
SplitButtonMinimalPerf.default 3629 3598 1.01:1
TreeWith60ListItems.default 130 129 1.01:1
AlertMinimalPerf.default 218 217 1:1
AttachmentSlotsPerf.default 917 915 1:1
ChatDuplicateMessagesPerf.default 213 213 1:1
CheckboxMinimalPerf.default 1729 1731 1:1
DatepickerMinimalPerf.default 4768 4779 1:1
DialogMinimalPerf.default 634 633 1:1
DropdownManyItemsPerf.default 543 543 1:1
HeaderMinimalPerf.default 288 287 1:1
RosterPerf.default 1786 1794 1:1
RefMinimalPerf.default 180 180 1:1
TableManyItemsPerf.default 1538 1536 1:1
AccordionMinimalPerf.default 118 119 0.99:1
BoxMinimalPerf.default 271 274 0.99:1
ListNestedPerf.default 444 450 0.99:1
MenuMinimalPerf.default 685 693 0.99:1
PopupMinimalPerf.default 526 531 0.99:1
CustomToolbarPrototype.default 2235 2249 0.99:1
ToolbarMinimalPerf.default 743 749 0.99:1
TooltipMinimalPerf.default 1927 1949 0.99:1
ChatWithPopoverPerf.default 294 301 0.98:1
TableMinimalPerf.default 325 331 0.98:1
ButtonMinimalPerf.default 128 132 0.97:1
ListCommonPerf.default 500 516 0.97:1
RadioGroupMinimalPerf.default 351 362 0.97:1
ListWith60ListItems.default 499 521 0.96:1
IconMinimalPerf.default 501 534 0.94:1

@fabricteam

fabricteam commented Oct 12, 2022

Copy link
Copy Markdown
Collaborator

Perf Analysis (@fluentui/react)

No significant results to display.

All results

Scenario Render type Master Ticks PR Ticks Iterations Status
BaseButton mount 1420 1369 5000
Breadcrumb mount 3480 3423 1000
Checkbox mount 3091 3107 5000
CheckboxBase mount 2758 2767 5000
ChoiceGroup mount 5119 5168 5000
ComboBox mount 1448 1501 1000
CommandBar mount 11195 11127 1000
ContextualMenu mount 12802 12681 1000
DefaultButton mount 1639 1611 5000
DetailsRow mount 4243 4222 5000
DetailsRowFast mount 4266 4270 5000
DetailsRowNoStyles mount 4134 4098 5000
Dialog mount 3596 3594 1000
DocumentCardTitle mount 675 690 1000
Dropdown mount 3759 3777 5000
FocusTrapZone mount 2374 2356 5000
FocusZone mount 2285 2302 5000
GroupedList mount 60975 67487 2
GroupedList virtual-rerender 28921 29480 2
GroupedList virtual-rerender-with-unmount 108936 107962 2
GroupedListV2 mount 657 654 2
GroupedListV2 virtual-rerender undefined err 2
GroupedListV2 virtual-rerender-with-unmount 664 667 2
IconButton mount 2226 2260 5000
Label mount 835 850 5000
Layer mount 4961 5013 5000
Link mount 962 988 5000
MenuButton mount 1901 1899 5000
MessageBar mount 2694 2775 5000
Nav mount 3776 3794 1000
OverflowSet mount 1586 1531 5000
Panel mount 2938 2928 1000
Persona mount 1446 1422 1000
Pivot mount 1873 1877 1000
PrimaryButton mount 1737 1744 5000
Rating mount 8245 8207 5000
SearchBox mount 1811 1785 5000
Shimmer mount 3298 3344 5000
Slider mount 2454 2409 5000
SpinButton mount 5547 5459 5000
Spinner mount 945 956 5000
SplitButton mount 3656 3630 5000
Stack mount 1034 1026 5000
StackWithIntrinsicChildren mount 2841 2795 5000
StackWithTextChildren mount 5747 5752 5000
SwatchColorPicker mount 12341 12349 5000
TagPicker mount 3106 3113 5000
TeachingBubble mount 96689 96465 5000
Text mount 916 978 5000
TextField mount 1905 1884 5000
ThemeProvider mount 1803 1812 5000
ThemeProvider virtual-rerender 1273 1290 5000
ThemeProvider virtual-rerender-with-unmount 2554 2529 5000
Toggle mount 1303 1322 5000
buttonNative mount 641 635 5000

Comment thread apps/stress-test/webpack/pageConfig.ts Outdated
Enables faster Webpack builds for Stress Test.
@spmonahan
spmonahan force-pushed the stress-test/multiple-ts-loaders branch from ba49800 to 989081c Compare October 13, 2022 14:59
@spmonahan spmonahan changed the title attempt at dropping ts-loader in favor of swc-loader Drop ts-loader in favor of swc-loader for Stress Test app Oct 13, 2022
@spmonahan
spmonahan marked this pull request as ready for review October 13, 2022 15:00
@spmonahan
spmonahan requested review from a team and micahgodbolt as code owners October 13, 2022 15:00
@spmonahan

Copy link
Copy Markdown
Contributor Author

/azp run

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines successfully started running 3 pipeline(s).

@spmonahan
spmonahan merged commit c964ec1 into microsoft:master Oct 14, 2022
NotWoods pushed a commit to NotWoods/fluentui that referenced this pull request Nov 18, 2022
Enables faster Webpack builds for Stress Test.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Stress test: investigate need for multiple Typescript loaders in Webpack config

6 participants