Code Monkey home page Code Monkey logo

css2less's People

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

css2less's Issues

error with media & animate

error with media query

@media screen and (min-width: 1200px){
    .login_registerBtn{
        width:30%;
    }
}
# parts = [ '.login_registerBtn' ]
***/node_modules/css2less/index.js:191
			var value = parts[1].trim();
			                    ^

TypeError: Cannot read property 'trim' of undefined

animate

@-webkit-keyframes animate {
  0% { -webkit-transform: perspective(160px); }
  50% { -webkit-transform: perspective(160px) rotateY(-180deg); }
  100% { -webkit-transform: perspective(160px) rotateY(-180deg) rotateX(-180deg); }
}

@keyframes animate {
  0% {
    transform: perspective(160px) rotateX(0deg) rotateY(0deg);
    -webkit-transform: perspective(160px) rotateX(0deg) rotateY(0deg);
  } 50% {
    transform: perspective(160px) rotateX(-180deg) rotateY(0deg);
    -webkit-transform: perspective(160px) rotateX(-180deg) rotateY(0deg) ;
  } 100% {
    transform: perspective(160px) rotateX(-180deg) rotateY(-180deg);
    -webkit-transform: perspective(160px) rotateX(-180deg) rotateY(-180deg);
  }
}
# parts = [ '0%' ]
***/node_modules/css2less/index.js:191
			var value = parts[1].trim();
			                    ^

TypeError: Cannot read property 'trim' of undefined

error with media query

awesome project :)
but it's failing with media queries. I guess its related with the { separator?

var css2less = require('css2less'),
  cssString = 'a {color:green;} @media (min-width: 550px) { a {color:red;} }',
  options = {},
  result;

result = css2less(cssString, options);
console.log(result);
λ node index.js

C:\Users\deschamps\Desktop\skeleton\node_modules\css2less\index.js:193
      var value = parts[1].trim();
                           ^
TypeError: Cannot call method 'trim' of undefined
    at me.matchVendorPrefixMixin (C:\Users\deschamps\Desktop\skeleton\node_modules\css2less\index.js:193:28)
    at me.addRule (C:\Users\deschamps\Desktop\skeleton\node_modules\css2less\index.js:260:20)
    at me.addRule (C:\Users\deschamps\Desktop\skeleton\node_modules\css2less\index.js:283:10)
    at me.addRule (C:\Users\deschamps\Desktop\skeleton\node_modules\css2less\index.js:283:10)
    at me.addRule (C:\Users\deschamps\Desktop\skeleton\node_modules\css2less\index.js:283:10)
    at me.addRule (C:\Users\deschamps\Desktop\skeleton\node_modules\css2less\index.js:283:10)
    at me.generateTree (C:\Users\deschamps\Desktop\skeleton\node_modules\css2less\index.js:327:12)
    at me.processLess (C:\Users\deschamps\Desktop\skeleton\node_modules\css2less\index.js:101:8)
    at module.exports (C:\Users\deschamps\Desktop\skeleton\node_modules\css2less\index.js:475:12)
    at Object.<anonymous> (C:\Users\deschamps\Desktop\skeleton\index.js:6:10)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.