【问题标题】:How to fix “Module build failed (from ./node_modules/postcss-loader/src/index.js)”如何修复“模块构建失败(来自 ./node_modules/postcss-loader/src/index.js)”
【发布时间】:2020-11-26 15:49:30
【问题描述】:

当我尝试运行我的应用程序时,我遇到了这个错误,我正在使用我一直使用的所有相同的依赖项,所以我对此感到非常困惑。

警告

在 ./assets/css/style.css

模块警告(来自 ./node_modules/postcss-loader/src/index.js):
(13:3) start 值有混合支持,考虑使用 flex-start 反而 友好错误 18:06:28 @ ./assets/css/style.css @ ./.nuxt/App.js @ ./.nuxt/index.js @ ./.nuxt/client.js @多事件源-polyfill webpack-hot-middleware/client?reload=true&timeout=30000&ansiColors=&overlayStyles=&path=%2F__webpack_hmr%2Fclient&name=client ./.nuxt/client.js

我该怎么办?

【问题讨论】:

    标签: vue.js npm nuxt.js postcss-loader


    【解决方案1】:

    我也遇到了这个警告:

    start value has mixed support, consider using flex-start instead

    虽然警告信息可以忽略,但是让我很不舒服。

    终于找到了一个合理的答案here,重点是flex-direction vs writing-mode direction

    1. flex-start (default): items are packed toward the start of the flex-direction.
    2. flex-end: items are packed toward the end of the flex-direction.
    3. start: items are packed toward the start of the writing-mode direction.
    4. end: items are packed toward the end of the writing-mode direction.
    

    【讨论】:

      【解决方案2】:
      build: {
          postcss: {
            preset: {
              features: {
                // Fixes: https://github.com/tailwindcss/tailwindcss/issues/1190#issuecomment-546621554
                "focus-within-pseudo-class": false
              }
            },
          },
      }
      

      【讨论】:

        猜你喜欢
        • 2021-02-17
        • 2021-07-15
        • 2020-07-12
        • 2019-09-29
        • 1970-01-01
        • 2021-04-17
        • 1970-01-01
        相关资源
        最近更新 更多