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

[RFC] Deprecate "down" responsive behavior #165

Closed
2 tasks
kettanaito opened this issue May 8, 2019 · 2 comments
Closed
2 tasks

[RFC] Deprecate "down" responsive behavior #165

kettanaito opened this issue May 8, 2019 · 2 comments
Labels
DX This issue improves developer's experience enhancement New feature or request needs:discussion Further information is requested possibly obsolete

Comments

@kettanaito
Copy link
Owner

kettanaito commented May 8, 2019

What:

I suggest to deprecate the "down" behavior of responsive props.

Why:

I have two concerns with the "down" behavior:

1. Desktop-first is not a good practice

Mobile-first has been a strong encouragement and industry standard for years now. Modern technologies also support this approach and teach developers to work with it (i.e. Bootstrap). It would be good to guide atomic-layout users to develop mobile-friendly layouts as the primary way of responsive props assignment. In this case less customization would be beneficial to the end implementation. This doesn't mean deprecation of the "only" behavior.

2. "Down" behavior is a technical cornerstone

Making this behavior work per-spec would imply more complex logic between mobile-first properties (which are encouraged by default). I would like to prevent support of features that demand serious refactoring without significant value to the library and end usage (such being Internet Explorer, for example).

How:

@kettanaito kettanaito added enhancement New feature or request needs:discussion Further information is requested DX This issue improves developer's experience labels May 8, 2019
@kettanaito kettanaito added this to the 1.0 milestone May 8, 2019
@kettanaito kettanaito modified the milestones: 1.0, 0.9.0 May 11, 2019
@kettanaito kettanaito modified the milestones: 0.9.0, 0.10.0 Jul 12, 2019
@kettanaito
Copy link
Owner Author

After numerous attempts to tackle this, I think the "down" behavior is here to stay. It's a powerful way to provide a cancellation behavior, and its alternative using "up" responsive props would be too verbose and unnecessary.

There are, however, changes to be made in the expectations toward the "down" responsive behavior:

  1. The "down" behavior should be considered as an explicit override, not the recommended way to evolve props permutations.
  2. The "down" behavioral responsive props are sensitive to declaration order, meaning that would override the preceding "up" responsive props, if met. In general, think of responsive props declaration as of CSS properties declarations (those are also sensitive to the declaration order).

This feature needs meaningful examples of usage to close this issue.

@kettanaito kettanaito removed this from the 0.10.0 milestone Nov 14, 2019
@kettanaito
Copy link
Owner Author

Conclusion

I have not found sufficient use cases and evidence that would support my idea of removing the "down" responsive prop behavior. So far it's quite useful in a lot of cases and I would prefer it to stay that way. Although its application is not always evident (#119), it can be systematized and understood through documentation.

Closing is for now, unless stronger evidence are found.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
DX This issue improves developer's experience enhancement New feature or request needs:discussion Further information is requested possibly obsolete
Projects
None yet
Development

No branches or pull requests

1 participant