Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

refactor(v2): i18n cleanups / refactors #4405

Merged
merged 3 commits into from
Mar 15, 2021
Merged

Conversation

longlho
Copy link
Contributor

@longlho longlho commented Mar 12, 2021

  • remove intl-locales-supported & intl since they're deprecated and only needed for IE11
  • clean up babel intl extractor
  • reset jest test timezone to UTC so it passes even for East Coast contributor

cc @slorber

@longlho longlho requested review from lex111 and slorber as code owners March 12, 2021 02:58
@facebook-github-bot facebook-github-bot added the CLA Signed Signed Facebook CLA label Mar 12, 2021
@netlify
Copy link

netlify bot commented Mar 12, 2021

@netlify
Copy link

netlify bot commented Mar 12, 2021

Deploy preview for docusaurus-2 ready!

Built without sensitive environment variables with commit 6bfdc1a

https://deploy-preview-4405--docusaurus-2.netlify.app

@github-actions
Copy link

github-actions bot commented Mar 12, 2021

⚡️ Lighthouse report for the changes in this PR:

Category Score
🟠 Performance 63
🟢 Accessibility 96
🟢 Best practices 100
🟢 SEO 100
🟢 PWA 95

Lighthouse ran on https://deploy-preview-4405--docusaurus-2.netlify.app/classic/

- remove intl-locales-supported & intl since they're deprecated and only
needed for IE11
- add new polyfills for node 12
- clean up babel intl extractor
- reset jest test timezone to UTC so it passes even for East Coast
contributor
@slorber slorber added the pr: polish This PR adds a very minor behavior improvement that users will enjoy. label Mar 12, 2021
Copy link
Collaborator

@slorber slorber left a comment

Choose a reason for hiding this comment

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

Thanks for cleaning up my AST processor :)

Not sure we want to remove intl-locales-supported, we don't use it in the browser but we actually use it for Node 12 lack of full ICU support.

We thought with @lex111 it would be simpler to load a polyfill in Node than asking our users to add full-icu support to Node 12. This is just a temporary solution until we require Node 14 as minimum version, including full ICU support.

Does it make sense to you?

@longlho
Copy link
Contributor Author

longlho commented Mar 12, 2021

Gotcha. What portion of docusaurus runs in Node? I thought it's client side only?

@slorber slorber changed the title chore: fix various intl stuff refactor(v2): i18n cleanups / refactors Mar 15, 2021
@slorber
Copy link
Collaborator

slorber commented Mar 15, 2021

Thanks, that looks good enough to merge.

I'll consider the doc warning to use Node 13+ or full icu is good enough, but we'll see if users get confused and add a more strict runtime error if needed

This was referenced Mar 17, 2021
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
CLA Signed Signed Facebook CLA pr: polish This PR adds a very minor behavior improvement that users will enjoy.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants