Giter Club home page Giter Club logo

wepy-plugin-px2units's Introduction

wepy框架px2units插件

npm version change-log

本插件不支持 wepy 2.x 版本,新的版本已经支持 postcss 插件了,文档地址:compiler-postcss,推荐使用:postcss-px2units

安装

npm install wepy-plugin-px2units --save-dev

配置wepy.config.js

module.exports.plugins = {
  'px2units': {
    filter: /\.wxss$/
    // 忽略 abc.wxss 文件示例
    // filter: /(?<!\/abc)\.wxss$/i
  },
};

参数说明

postcss-px2units

wepy-plugin-px2units's People

Contributors

yingye 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

Watchers

 avatar  avatar  avatar

Forkers

vimming xrosliang

wepy-plugin-px2units's Issues

拷贝wxss的时候op.code是空的

 prefixer.process(op.code, { from: op.file }).then((result) => {

我在src下面了放了一些第三方的小程序组件,wepy会把里面的文件夹拷贝到dist下面。
使用px2units的时候,也希望把第三方组件里面的px改成rpx。
build的时候还会提示

     [WARNING] Error: PostCSS received null instead of CSS string

可否添加判断op.code为空的时候 用fs读取op.file的文件内容

关于base64的值被转换rpx问题

小程序添加的第三方字体库,类似iconfont,转成base64后,因为值含有px字母被转义rpx,导致字体失效,有没有配置信息能修改的,忽略掉指定的wxss

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.