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

fix: accept any order of params #45

Merged
merged 1 commit into from
Jan 6, 2021
Merged

Conversation

semoal
Copy link
Owner

@semoal semoal commented Jan 5, 2021

  • Export DEFAULT_SETTINGS
  • Merge DEFAULT_SETTINGS if they are not equals to default, this is helpful to pass inside settings CustomThemeProvider and keep the logic of disableThemePreview
  • Accept as second parameter a custom context (this was the old way of doing things)
  • Accept inside settings parameter CustomThemeProvider

I think it's all 👍🏻

@commit-lint
Copy link

commit-lint bot commented Jan 5, 2021

Bug Fixes

  • accept any order of params (cbbf6aa)

Contributors

semoal

Commit-Lint commands

You can trigger Commit-Lint actions by commenting on this PR:

  • @Commit-Lint merge patch will merge dependabot PR on "patch" versions (X.X.Y - Y change)
  • @Commit-Lint merge minor will merge dependabot PR on "minor" versions (X.Y.Y - Y change)
  • @Commit-Lint merge major will merge dependabot PR on "major" versions (Y.Y.Y - Y change)
  • @Commit-Lint merge disable will desactivate merge dependabot PR
  • @Commit-Lint review will approve dependabot PR
  • @Commit-Lint stop review will stop approve dependabot PR

@semoal semoal force-pushed the fix--order-of-parameters-broken branch from a194f0a to cbbf6aa Compare January 5, 2021 21:25
@semoal
Copy link
Owner Author

semoal commented Jan 5, 2021

@jimmy-guzman about Typescript component logic of required/not required, tell me if this is enough.

export type CustomThemeProvider = React.ComponentType<{ theme: Theme, children: React.ReactNode }>

@jimmy-guzman
Copy link
Contributor

@semoal yeah that's enough. Thanks.

@@ -0,0 +1,17 @@
export function isClassComponent(component: any): boolean {
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
export function isClassComponent(component: any): boolean {
// eslint-disable-next-line @typescript-eslint/no-explicit-any
export function isClassComponent(component: any): boolean {

Just a thought.

@semoal semoal merged commit 28c294a into master Jan 6, 2021
@semoal semoal deleted the fix--order-of-parameters-broken branch January 6, 2021 09:12
semoal pushed a commit that referenced this pull request Jan 6, 2021
### Bug Fixes

* Compatibility with older versions ([#45](#45)) ([28c294a](28c294a))
@semoal
Copy link
Owner Author

semoal commented Jan 6, 2021

🎉 This PR is included in version 1.7.1 🎉

The release is available on:

Your semantic-release bot 📦🚀

@semoal semoal added the released label Jan 6, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants