vuejs / jsx-vue2

monorepo for Babel / Vue JSX related packages
https://jsx-vue2-playground.netlify.app/
1.47k stars 96 forks source link

过滤掉jsx属性中的换行符 #308

Open 2096903746 opened 1 year ago

2096903746 commented 1 year ago
  render (h) {
      return (
        <div style='
                line-height: 16px;
                text-align: left;
              '>
              </div>
    )}

以上jsx如果不过滤换行符,会报错: Unterminated string constant

在老版本jsx插件中, 是会过滤掉属性中的换行符,老版本参考: [babel-plugin-transform-vue-jsx](https://github.com/vuejs/babel-plugin-transform-vue-jsx/tree/master) /index.js

netlify[bot] commented 1 year ago

Deploy Preview for jsx-vue2-playground ready!

Name Link
Latest commit e3dd1dc324cace1a81ee81783bbecf9de1b5f565
Latest deploy log https://app.netlify.com/sites/jsx-vue2-playground/deploys/64a400b7fd1cb90008f0ec1d
Deploy Preview https://deploy-preview-308--jsx-vue2-playground.netlify.app/
Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.