Small boilerplate with TailwindCSS, PostCSSΒ and StyleLine.
This workshop uses VSCode since the Tailwind creators maintain a VSCode extension providing IntelliSense for Tailwind.
However, Tailwind is supported in WebStorm as of monday, and in Rider, PhpStorm and PyCharm under the Early Access Program.
Consider the Auto-Open Markdown Preview for reading the README.md
-files in VSCode.
npm install
πββοΈnpm run build
ποΈOpen with Live Server
πProvides autocomplete, linting, hover-preview and syntax-highlighting. The awesomeness lies in that it includes all the customizations in tailwind.config.js
that form your design system.
Enforces consistent ordering of classes. Which reduces the cognitive load of dealing with multiple classnames.
Simple solution to launch a local development server with live reload.
VSCode's default CSS validator disallows unknown at-rules, which includes a few Tailwind at-rules (@tailwind
, @responsive
etc.).
There are alternative solutions that configures VSCode, but I've opted for Stylelint because "it is to style sheets what ESLint is for JavaScript".
Stylelint is configured in stylelint.config.js
with a recommended standard configuration that enforce common stylistic conventions found in reputable CSS styleguides, including: The Idiomatic CSS Principles,
Google's CSS Style Guide and Airbnb's Styleguide.