Skip to content
This repository was archived by the owner on Jul 9, 2025. It is now read-only.

Conversation

@GeoffCoxMSFT
Copy link
Member

@GeoffCoxMSFT GeoffCoxMSFT commented Apr 7, 2021

Description

The l10n:babel extracts strings from the source code.
It is currently including lib folders which contain built JS with the same formatMessage calls as the TS source.
This creates a lot of extra files in the l10ntemp folder which later l10n commands have to process - slowing the build.

This PR excludes those folders using the wildcard search pattern in the ignore section of the babel config file.
I tried to use the regex format, but it doesn't seem to work and babel won't output information about matches.

Task Item

#minor

Screenshots

Old yarn l10n build time (on my dev machine): 115 s
New yarn l10n build time (on my dev machine): 95 s
Savings: 20 s

Copy link
Contributor

@a-b-r-o-w-n a-b-r-o-w-n left a comment

Choose a reason for hiding this comment

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

@beyackle can you also take a look at this?

// TODO: It would be nice to use the regular expression matching.
// It would be nice to ignore the lib folders rather than listing them one at a time.
// However, as of 4/2021 it doesn't seem to work.
// We have the added complexity that packages/lib contains folders we DO want to process.
Copy link
Contributor

Choose a reason for hiding this comment

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

Yeah. Easiest thing to do is probably just remove the lib directory and move the contents up a directory.

Copy link
Member Author

Choose a reason for hiding this comment

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

Agree. Didn't want to create any major restructure so close to release.

Copy link
Contributor

Choose a reason for hiding this comment

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

I definitely agree here, too. It keeps tripping me up that we have regular non-compiled code in a lib folder (and then each package in there has compiled stuff in its own lib folder).

// TODO: It would be nice to use the regular expression matching.
// It would be nice to ignore the lib folders rather than listing them one at a time.
// However, as of 4/2021 it doesn't seem to work.
// We have the added complexity that packages/lib contains folders we DO want to process.
Copy link
Contributor

Choose a reason for hiding this comment

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

I definitely agree here, too. It keeps tripping me up that we have regular non-compiled code in a lib folder (and then each package in there has compiled stuff in its own lib folder).

@coveralls
Copy link

Coverage Status

Coverage remained the same at 51.614% when pulling 477db92 on gcox/l10nperf into 9c1c17e on main.

@GeoffCoxMSFT GeoffCoxMSFT merged commit 9f6c16e into main Apr 7, 2021
@GeoffCoxMSFT GeoffCoxMSFT deleted the gcox/l10nperf branch April 7, 2021 19:04
@cwhitten cwhitten mentioned this pull request May 20, 2021
lei9444 pushed a commit to lei9444/BotFramework-Composer-1 that referenced this pull request Jun 15, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants