0.8.252 • Published 7 years ago

postcss-parse-atrule-events v0.8.252

Weekly downloads
5
License
MIT
Repository
github
Last release
7 years ago

postcss-parse-atrule-events

Postcss plugin for auto generating code

Installation

$ npm install postcss-parse-atrule-events --save

Usage

Via Node API

let result = require('postcss-parse-atrule-events').parse('code');

Example

Input:

    @on load {
        @fetch my/async/styles1.css;
        @fetch my/async/styles1.css;
    }
    .my-critical-path-selector {
        width: 100px;
        height: 100px;
    }

Output:

let output = [
     {
         attachOn: "load",
         imports: [
             "my/async/styles1.css",
             "my/async/styles1.css"
         ],
         styles: "",
         type: "on",
     },
     {
         attachOn: "immediately",
         imports: [],
         styles: ".my-critical-path-selector { width: 100px; height: 100px; }",
         type: "default",
     },
 ];

Tests

git clone https://github.com/SerkanSipahi/app-decorators.git
cd app-decorators/packages/postcss-parse-atrule-events
npm run test
0.8.252

7 years ago

0.8.251

7 years ago

0.8.250

7 years ago

0.8.249

7 years ago

0.8.248

7 years ago

0.8.247

7 years ago

0.8.245

7 years ago

0.8.244

7 years ago

0.8.242

7 years ago

0.8.241

7 years ago

0.8.240

7 years ago

0.8.239

7 years ago

0.8.238

7 years ago

0.8.237

7 years ago

0.8.236

7 years ago

0.8.235

7 years ago

0.8.234

7 years ago

0.8.233

7 years ago

0.8.232

7 years ago

0.8.231

7 years ago

0.8.230

7 years ago

0.8.229

7 years ago

0.8.228

7 years ago

0.8.227

7 years ago

0.8.226

7 years ago

0.8.225

7 years ago

0.8.224

7 years ago

0.8.223

7 years ago

0.8.222

7 years ago

0.8.221

7 years ago

0.8.220

7 years ago

0.8.219

7 years ago

0.8.218

8 years ago

0.8.217

8 years ago

0.8.216

8 years ago

0.8.215

8 years ago

0.8.214

8 years ago

0.8.213

8 years ago

0.8.212

8 years ago

0.8.211

8 years ago

0.8.210

8 years ago

0.8.209

8 years ago

0.8.208

8 years ago

0.8.207

8 years ago

0.8.206

8 years ago