const sass = require('node-sass');
const tildeImporter = require('node-sass-tilde-importer');

module.exports = (data, file) => {
  const { css } = sass.renderSync({
    data,
    file,
    importer: tildeImporter,
  });
  return css.toString('utf8');
};
