浏览代码

fix: asset warnigns on windows (#3220)

Miles Murgaw 7 月之前
父节点
当前提交
6da7226370
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      packages/manganis/manganis-macro/src/asset.rs

+ 1 - 1
packages/manganis/manganis-macro/src/asset.rs

@@ -85,7 +85,7 @@ impl ToTokens for AssetParser {
         let option_source = &self.options;
 
         // generate the asset::new method to deprecate the `./assets/blah.css` syntax
-        let method = if asset.input.is_relative() {
+        let method = if !asset.input.starts_with("/") {
             quote::quote! { new_relative }
         } else {
             quote::quote! { new }