8000 feat(core): allow plugin/preset config to contain false/null by Josh-Cena · Pull Request #7124 · facebook/docusaurus · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

feat(core): allow plugin/preset config to contain false/null #7124

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

Merged
merged 2 commits into from
Apr 7, 2022

Conversation

Josh-Cena
Copy link
Collaborator

Motivation

With this PR the values of false and null will be properly recognized in types and code, allowing people to write

plugins: [
  isProd && "sitemap",
  buildFast ? null : "typedoc",
],

instead of having to dynamically push values.

Our validation currently allows false, but this isn't really filtered out and leads to bugs in later stages. Moreover this is a type-checking error.

Have you read the Contributing Guidelines on pull requests?

Yes

@Josh-Cena Josh-Cena added the pr: new feature This PR adds a new API or behavior. label Apr 7, 2022
@Josh-Cena Josh-Cena requested review from slorber and lex111 as code owners April 7, 2022 06:23
@facebook-github-bot facebook-github-bot added the CLA Signed Signed Facebook CLA label Apr 7, 2022
@netlify
Copy link
netlify bot commented Apr 7, 2022

[V2]

Name Link
🔨 Latest commit 79dd7b9
🔍 Latest deploy log https://app.netlify.com/sites/docusaurus-2/deploys/624e85054b23fa0008ba5208
😎 Deploy Preview https://deploy-preview-7124--docusaurus-2.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site settings.

@github-actions
Copy link
github-actions bot commented Apr 7, 2022

⚡️ Lighthouse report for the changes in this PR:

Category Score
🟠 Performance 60
🟢 Accessibility 100
🟢 Best practices 92
🟢 SEO 100
🟢 PWA 90

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

@github-actions
Copy link
github-actions bot commented Apr 7, 2022

Size Change: 0 B

Total Size: 804 kB

ℹ️ View Unchanged
Filename Size
website/.docusaurus/globalData.json 49.9 kB
website/build/assets/css/styles.********.css 105 kB
website/build/assets/js/main.********.js 610 kB
website/build/index.html 38.6 kB

compressed-size-action

@slorber slorber merged commit f9c0a5a into main Apr 7, 2022
@slorber slorber deleted the jc/falsy-plugin branch April 7, 2022 13:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed Signed Facebook CLA pr: new feature This PR adds a new API or behavior.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants
0