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

Prevent plugin from breaking when no object is passed #17

Closed
hacknug opened this issue Apr 21, 2020 · 4 comments
Closed

Prevent plugin from breaking when no object is passed #17

hacknug opened this issue Apr 21, 2020 · 4 comments

Comments

@hacknug
Copy link

hacknug commented Apr 21, 2020

This would be a matter of providing an empty object as fallback.

Can open a PR with the changes if you want.

@bentzibentz
Copy link
Owner

Good idea.

Feel free to open a PR, I will merge it.

@bentzibentz
Copy link
Owner

bentzibentz commented Apr 21, 2020

I tested it with an empty settings object

require('tailwindcss-animatecss')({ settings: {}, variants: ['responsive'], }),

it worked as expected, the fallback values are used.

Can you describe your problem a bit further?

@hacknug
Copy link
Author

hacknug commented Apr 29, 2020

I tested it with an empty settings object

Yeah, I meant prevent it from breaking when you pass absolutely nothing to the plugin. Right now it breaks because it tries to destructure undefined or null or something.

@bentzibentz
Copy link
Owner

Fixed in v3.0.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants