Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

在生成的代码中使用单引号代替双引号,或新增配置可由使用者定义 #38

Open
macroxing opened this issue Jun 4, 2017 · 0 comments

Comments

@macroxing
Copy link

macroxing commented Jun 4, 2017

目前在生成的代码中,存在双引号。

如:models.create 在定义了 entry 时,会在 entry 中新增对于 model 的引用

app.model(require("./model/name")

该语句中存在双引号,在配置了以单引号作为引号类型的lint规则下会抛错

建议做一个全局配置,引号的类型可由使用者定义,并且默认引号类型为单引号。如:

import { config } from 'dva-ast'

config({
  quoteType: 'single'|'double'
})
@macroxing macroxing changed the title 使用 import 在生成的代码中使用单引号代替双引号,或新增配置可由使用者定义 Jun 4, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant