Atomizer tool
Edit on GithubAtomizer is a tool (npm, github) for generating ACSS stylesheets.
Atomizer creates CSS style declarations based on ACSS classes it finds in your project. This means that your style sheets are always up-to-date without the need for writing a single CSS declaration manually [1].
For example, if your project was a single page containing:
Atomizer would create a style sheet containing these rules:
For the sake of readability, CSS classes on this page do not include the escape character (\
) where it should be needed.
If, for example, you decided to update the classes like below:
Then Atomizer would update the style sheet (removing D(b)
and replacing Fz(20px)
with Fz(18px)
) to match exactly what is being used inside the project:
Integrations #
Build #
So how do you integrate Atomizer into your project? You can use Grunt, Gulp, WebPack, Make, Graddle, or any other task runner/build system you'd like.
Here's a few open source projects we know about:
- Grunt: grunt-atomizer (Created by the Atomizer team)
- Webpack: atomic-loader
- Gulp: gulp-atomizer
- Clojure : boot-atomizer (Boot-Task for clojurescript )
If you create your own, please let us know!
Example: Grunt
If you're using the Grunt task runner, you can use grunt-atomizer to configure and execute Atomizer:
Web Tools #
For a simple web interface to help you learn about Atomizer and ACSS, check out ATOMIZER WEB, a tool built by Pankaj Parashar. Paste some markup or ACSS classes and ATOMIZER WEB will show you the rendered CSS. The tool also gives you access to the configuration where you can set your own break-points, variables, and more.
- This is true for non-custom classes [↩].