【问题标题】:Mindscape Web Workbench Sass unknown mixinMindscape Web Workbench Sass 未知 mixin
【发布时间】:2012-04-04 06:11:31
【问题描述】:

我目前正在使用 Mindscape Web Workbench 从 sass 创建 css。我正在使用导入所有其他文件的整体 site.scss 文件。

  /*** Infrastructure ***************************************/
  /**********************************************************/
  @import "../../Infrastructure/_Common";
  @import "../../Layouts/Layout1/_Layout";

  /*** Theming **********************************************/
  /**********************************************************/
  @import "_Theme";

我在 _Common 中定义的 Mixin 在 _Theme 中是未知的。当 site.css 被编译时,它一切正常,但 Mindscape Web Workbench 的智能感知认为 mixins 是未定义的。插件有没有办法知道这些 mixin 已定义?

【问题讨论】:

    标签: visual-studio-2010 sass


    【解决方案1】:

    “@import”的 SASS 语法与 .Net 的语法冲突。在 .Net 中使用 SASS 时,将“@import”替换为关键字“@reference”,并注释掉 @reference (s)。请参阅http://getcassette.net/documentation/AssetReferences 了解更多信息。

    上面的代码是:

    /*** Infrastructure ***************************************/
    /**********************************************************/
    /*
    @reference "../../Infrastructure/_Common";
    @reference "../../Layouts/Layout1/_Layout";
    */
    
    /*** Theming **********************************************/
    /**********************************************************/
    /*
    @reference "_Theme";
    */
    

    【讨论】:

      猜你喜欢
      • 2015-05-14
      • 2016-01-03
      • 2018-10-24
      • 2022-11-03
      • 2014-11-17
      • 2013-03-14
      • 2011-10-31
      • 2014-07-07
      • 2023-04-02
      相关资源
      最近更新 更多