Skip to content
This repository has been archived by the owner on Sep 7, 2021. It is now read-only.

The linter spec for data.constituent_properties can't handle the all property #526

Closed
wbamberg opened this issue Jul 29, 2020 · 3 comments
Closed

Comments

@wbamberg
Copy link

In the course of mdn/sprints#3323, Chris hit a snag: the CSS all property is a shorthand for all properties with a few exceptions.

It doesn't seem at all desirable to list all properties here. The best solution I can think of is to add another allowable form to the linter spec:

"This property is a shorthand all CSS properties, with the exception of:"

I don't love this since it's very clearly a workaround for a single page, but it's not too bad.

Thoughts, @ddbeck / @chrisdavidmills ?

@ddbeck
Copy link
Contributor

ddbeck commented Jul 29, 2020

In general, I'm fine with making explicit workarounds for specific pages. The recipes and linter spec should be a tool, not an anchor. It's making exceptions routine, not the exceptions themselves, that smells off to me.

For this page, I wonder whether we want to have a constituent properties section at all? A one-off recipe without it would be easy to implement and would not implicate the linter spec.

If we do want it, then I'm happy with this proposed exceptional text. For the record though, in a structured Markdown world, I'd expect an absurdly long frontmatter with a list of all the constituent properties and some special-case code that produces the aforementioned text.

@wbamberg
Copy link
Author

I'm not keen on having a special recipe just for this. I'd prefer to pretend this isn't a shorthand property at all, and that might be better actually.

Especially given:

in a structured Markdown world

I hadn't thought of this. You are right of course, and that means the special-case code and special-case metadata saying this page is special, just for one page.

So I think it would be better all round to call all a normal property, and describe its behavior in the prose.

@ddbeck
Copy link
Contributor

ddbeck commented Jul 29, 2020

So I think it would be better all round to call all a normal property, and describe its behavior in the prose.

Oh yeah, this is obviously the right thing to do, now that I've accidentally made the reductio ad absurdum proposal. A regular property page could still have a constituent property section even, in prose.*.

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

No branches or pull requests

2 participants