lit.dev icon indicating copy to clipboard operation
lit.dev copied to clipboard

Include "postcss-lit" package to the docs as a recommended solution to process css

Open iSokrat opened this issue 2 years ago • 3 comments

Should this be an RFC?

  • [X] This is not a substantial change

Which package is this a feature request for?

Other/unknown (please mention in description)

Description

There is a package, which provides ability to process css inside lit components. For now, it's not mentioned anywhere in the repo as a solution which should be used in case if someone wants to integrate some tool like stylelint (although, it's mentioned in that repo).

In postcss-lit this discussion was also initiated since for now it's only one open source package with well defined docs which helps to do this (actually, there was a proposal to include that package to lit project and support it accordingly).

Alternatives and Workarounds

In case if we don't use this package, need to implement own custom solutions to somehow integrate the tools like stylelint in the project or, moreover, implement own lint tools for styles.

There is also one article prepared by creator of postcss-lit, how to adopt stylelint-processor-styled-components for lit components.

iSokrat avatar Mar 30 '23 09:03 iSokrat

My preference would be to go even further and move the project into the lit org so I'm not keeping it aligned to lit solo.

However we did have some discussions recently about recommending external CSS in these situations over embedded.

IMO though the standard is still to embed your CSS for now so it's something we should support officially.

We can easily add it to the docs I think as a start

But I could do with some help making it a more robust solution too

43081j avatar Mar 30 '23 11:03 43081j

@43081j Do we need to ping someone to move forward with this topic?

iSokrat avatar Apr 12 '23 16:04 iSokrat

ill see if i can raise it in the weekly lit eng catch up

meanwhile its also roughly tracked here as a larger issue: https://github.com/lit/lit/discussions/3705

43081j avatar Apr 13 '23 08:04 43081j