Coder Social home page Coder Social logo

umi-plugin-tailwindcss's People

Contributors

dewfall123 avatar hiyangguo avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

umi-plugin-tailwindcss's Issues

❤感谢

感谢作者做出这么好用的插件,十分的便捷.

在这里对作者说一句谢谢.

帮助我节省了很多时间.

感谢您辛勤的付出.谢谢.

补充 antd 中的 icon 的位置修复

由于 tailwindcss 默认针对 svg 使用了

svg{
 vertical-align:middle;
}

导致 所有 antd 中的 icon 都会往下偏移,就像下图这样

image

现在我每次使用都会在 global 里加一条

svg {
  vertical-align: initial;
}

来修复 icon 偏移的问题。

这部分能否集成在插件里?

jit模式不生效

开启jit模式后,jit的特性不生效,原来普通的特性也失效了。

无法使用 autoprefixer

无法使用 autoprefixer

image

package.json

"tailwindcss": "^2.2.10",
"umi": "^3.5.17",
"umi-plugin-tailwindcss": "^3.1.5"

taikwind.config.js

module.exports = {
  // mode: 'jit',
  // jit document: https://tailwindcss.com/docs/just-in-time-mode
  // purge: ['./src/**/*.html', './src/**/*.tsx', './src/**/*.ts'],
  darkMode: false, // or 'media' or 'class'
  theme: {},
  variants: {
    extend: {},
  },
  plugins: [
    require('autoprefixer'),
  ],
};

缺少 -webkit- 前缀

.bg-clip-text {
-    -webkit-background-clip: text;
    background-clip: text;
}

每次改一下重新编译时间较长(20s左右)

基于 Ant Design Pro 做了下尝试,用了 less 文件。

@tailwind utilities;

.test {
  @apply rounded-md bg-white p-4;
}

然后每次修改 @apply 里的内容,导致重新编译,用时较长(大约 20s 左右),这个是插件的问题还是 umi 的问题?

存在APP_ROOT环境变量的情况下,tailwind.config.js识别错误导致purge失败

electron项目的main、renderer目录结构,因此设置了 APP_ROOT=src/renderer 。复现步骤:

打包输出的css文件引入了全部tailwind样式(2MB+)。但复制一份tailwind.config.js到根目录后正常,感觉tailwind是直接读process.cwd()了,插件层面应该有办法给tailwincss指定配置文件路径?

安装失败

$ yarn add umi-plugin-tailwindcss -D
yarn add v1.22.5
warning package-lock.json found. Your project contains lock files generated by tools other than Yarn. It is advised not to mix package managers in order to avoid resolution inconsistencies caused by unsynchronized lock files. To clear this warning, remove package-lock.json.
[1/4] Resolving packages...
[2/4] Fetching packages...
info [email protected]: The platform "win32" is incompatible with this module.
info "[email protected]" is an optional dependency and failed compatibility check. Excluding it from installation.
info [email protected]: The platform "win32" is incompatible with this module.
info "[email protected]" is an optional dependency and failed compatibility check. Excluding it from installation.
[3/4] Linking dependencies...
warning " > @ant-design/[email protected]" has unmet peer dependency "antd@^4.x".
warning "@ant-design/pro-layout > @ant-design/[email protected]" has unmet peer dependency "[email protected]".
warning "@ant-design/pro-layout > @ant-design/[email protected]" has incorrect peer dependency "react@^16.x".
warning "@ant-design/pro-layout > @ant-design/[email protected]" has unmet peer dependency "[email protected]".
warning "@ant-design/pro-layout > @ant-design/[email protected]" has incorrect peer dependency "react@^16.x".
warning "@ant-design/pro-layout > [email protected]" has incorrect peer dependency "[email protected]".
warning "@ant-design/pro-layout > [email protected]" has incorrect peer dependency "[email protected]".
warning "@umijs/preset-react > @umijs/[email protected]" has unmet peer dependency "@ant-design/icons@^4.0.0".
warning "@umijs/preset-react > @umijs/plugin-dva > [email protected]" has unmet peer dependency "[email protected]".
warning "@umijs/preset-react > @umijs/plugin-dva > [email protected]" has incorrect peer dependency "react@^16.8.4".
warning "@umijs/preset-react > @umijs/plugin-dva > [email protected]" has incorrect peer dependency "react-dom@^16.8.4".
warning "@umijs/preset-react > @umijs/plugin-dva > [email protected]" has unmet peer dependency "dva-core@^1.1.0 | ^1.5.0-0 | ^1.6.0-0".
warning "@umijs/preset-react > @umijs/plugin-locale > [email protected]" has incorrect peer dependency "react@^16.3.0".
warning "@umijs/preset-react > @umijs/plugin-antd > antd > [email protected]" has unmet peer dependency "dayjs@^1.8.30".
warning "@umijs/preset-react > @umijs/plugin-dva > dva > [email protected]" has incorrect peer dependency "react@^16.4.0".
warning "@umijs/preset-react > @umijs/plugin-dva > dva > [email protected]" has unmet peer dependency "react-router@^4.3.1 || ^5.0.0".
[4/4] Building fresh packages...

success Saved lockfile.
success Saved 28 new dependencies.
info Direct dependencies
└─ [email protected]
info All dependencies
├─ @fullhuman/[email protected]
├─ [email protected]
├─ [email protected]
├─ [email protected]
├─ [email protected]
├─ [email protected]
├─ [email protected]
├─ [email protected]
├─ [email protected]
├─ [email protected]
├─ [email protected]
├─ [email protected]
├─ [email protected]
├─ [email protected]
├─ [email protected]
├─ [email protected]
├─ [email protected]
├─ [email protected]
├─ [email protected]
├─ [email protected]
├─ [email protected]
├─ [email protected]
├─ [email protected]
├─ [email protected]
├─ [email protected]
├─ [email protected]
├─ [email protected]
└─ [email protected]
$ umi generate tmp
Specified Tailwind config file "E:\FrontEnd\typescript-react\umi-tailwind\tailwind.config.js" doesn't exist.
Error: Specified Tailwind config file "E:\FrontEnd\typescript-react\umi-tailwind\tailwind.config.js" doesn't exist.
at _default (E:\FrontEnd\typescript-react\umi-tailwind\node_modules\tailwindcss\lib\lib\registerConfigAsDependency.js:16:11)
at E:\FrontEnd\typescript-react\umi-tailwind\node_modules\tailwindcss\lib\index.js:85:58
at creator (E:\FrontEnd\typescript-react\umi-tailwind\node_modules\postcss\lib\postcss.es6:111:34)
at Object.fn (E:\FrontEnd\typescript-react\umi-tailwind\node_modules\umi-plugin-tailwindcss\dist\index.js:51:13)
at E:\FrontEnd\typescript-react\umi-tailwind\node_modules@umijs\core\lib\Service\Service.js:573:37
at Generator.next ()
at asyncGeneratorStep (E:\FrontEnd\typescript-react\umi-tailwind\node_modules@umijs\core\lib\Service\Service.js:108:103)
at _next (E:\FrontEnd\typescript-react\umi-tailwind\node_modules@umijs\core\lib\Service\Service.js:110:194)
at E:\FrontEnd\typescript-react\umi-tailwind\node_modules@umijs\core\lib\Service\Service.js:110:364
at new Promise ()
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/add for documentation about this command.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.