csswordpresssassprepros

SASS invalid CSS due to comment


I'm currently going through an issue with the SASS compiler. I've started creating the basic layout for a Wordpress website using CSS but the compiler, Prepros is not letting me compile the files. I fear that it may have something to do with the comment blocks at the start of the style.css file. If you know what the issue may be, then that will be great.

style.sass

/*
    Theme Name: Xtra Child
    Theme URI:  http://themeforest.net/user/Codevz/portfolio
    Description:Sample child theme of Xtra theme for customization.
    Author:     Codevz
    Author URI: http://themeforest.net/user/Codevz
    Template:   xtra
    Version:    1.0
*/


@import "global.sass" 

The error log I've gotten from Prepros :

If you can give me an idea on how to combat this problem, that would be really great. Thank you for your time. :)


Solution

  • Try this instead:

    /*Theme Name: Xtra Child
     *Theme URI:  http://themeforest.net/user/Codevz/portfolio
     *Description:Sample child theme of Xtra theme for customization.
     *Author:     Codevz
     *Author URI: http://themeforest.net/user/Codevz
     *Template: xtra
     *Version:    1.0 */
    

    With SASS comments the closing comment */ needs to be on the last line, not underneath. Hopefully that works