cosmos-css
v0.12.2
Published
The css framework for personal practice.
Downloads
8
Readme
cosmos-css
The css framework for personal practice.
Installation
NPM
$ npm install cosmos-css
Configuration
SCSS
// In your style.scss file.
@import 'app-variables'; // Customize variables for application.
@import 'node_modules/cosmos-css/src/scss/cosmos';
...
JS
// In your script.js (webpack entry file)
import Cosmos from 'cosmos-css';
window.Cosmos = Cosmos;
const cosmos = Cosmos.load({ /* options */ });
// --- or ---
window.Cosmos = Cosmos;
const cosmos = new Cosmos({ /* options */ }).init();
HTML
In your index.html file
<!-- in <head> tag -->
<link rel="stylesheet" href="dist/css/style.css">
...
<!-- in the end of <body> tag -->
<script src="https://cdn.polyfill.io/v2/polyfill.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/babel-polyfill/6.23.0/polyfill.js"></script>
<script src="dist/js/script.js"></script>
Usage
CSS Components and JS Modules
See wiki page.
View demo
https://archco.github.io/cosmos-css/
Change Log
License
The MIT License.