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

deny viewport cascading? #23

Open
nelsonpecora opened this issue Mar 29, 2016 · 4 comments
Open

deny viewport cascading? #23

nelsonpecora opened this issue Mar 29, 2016 · 4 comments

Comments

@nelsonpecora
Copy link
Contributor

One of the main reasons we use rfn is that we can specify viewports without dealing with viewport cascading. To this end, we should have an option (--strict?) that will fail if two viewports overlap.

Things that would be acceptable in strict mode:

folder/
  all.css

folder/
  0-100.css
  100+.css

folder/
  0-600.css
  600-1024.css
  1024+.css

Things that would not be acceptable in strict mode:

folder/
  all.css
  0-100.css

folder/
  0-600.css
  200-600.css

folder/
  600+.css
  1024+.css
@cruzanmo
Copy link

When most styles are shared across viewports, it is useful to have an all.css with the shared styles and then use the viewport-specific files only where adjustments are needed.

e.g.

all.css
0-600.css
600-1024.css
1024+.css

@nelsonpecora
Copy link
Contributor Author

Yeah but we explicitly don't want that, right? If we don't want cascading between viewports (with the tradeoffs that entails), then we should block it.

@cruzanmo
Copy link

cruzanmo commented Apr 1, 2016

I would consider all filenames that contain numbers to be viewport-specific, whereas all.css is not.

@nelsonpecora
Copy link
Contributor Author

Hmm, fair point. Also the fact that certain css things cannot live inside media queries (@Keyframes, etc) means we can't enforce that.

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

No branches or pull requests

2 participants