Skip to content
This repository has been archived by the owner on Nov 4, 2018. It is now read-only.

现在 antd-init 命令只能生成 web 项目 #130

Open
warmhug opened this issue Nov 15, 2016 · 13 comments
Open

现在 antd-init 命令只能生成 web 项目 #130

warmhug opened this issue Nov 15, 2016 · 13 comments
Assignees

Comments

@warmhug
Copy link
Contributor

warmhug commented Nov 15, 2016

mobile 项目,要不要有个什么命令、自动生成项目?

@afc163
Copy link
Member

afc163 commented Nov 15, 2016

@sorrycc
Copy link
Contributor

sorrycc commented Nov 16, 2016

对内有脚手架的,对外项目的推荐用 dva-cli 生成,然后手动添加 antd-mobile 依赖。

@benjycui
Copy link
Contributor

antd-init不是降级为 demo 用途了么。

@afc163
Copy link
Member

afc163 commented Nov 16, 2016

手动添加 antd-mobile 基本不可行,需要 babel-plugin-importpostcss-plugin-px2rem、高清方案脚本等等才能正常跑起来。

@sorrycc
Copy link
Contributor

sorrycc commented Nov 16, 2016

有文档吗?

@afc163
Copy link
Member

afc163 commented Nov 16, 2016

目前没文档:ant-design/ant-design-mobile#56

@benjycui
Copy link
Contributor

觉得还是得把 antd antd-mobile 的脚手架集成进 dva-cli,然后用户在 new|init 时可以选择其中一个 antd|antd-mobile|plain

@sorrycc
Copy link
Contributor

sorrycc commented Nov 17, 2016

有没有可能在 dva init 执行一个 script 完成 antd 和 antd-mobile 的初始工作?

@benjycui
Copy link
Contributor

执行一个 script 完成 antd 和 antd-mobile 的初始工作?

要自动完成?还是让用户下载这个 script?

如果自动完成,其实就是集成进 dva-cli 了。

@sorrycc
Copy link
Contributor

sorrycc commented Nov 17, 2016

看了下 MobileDemo,如果不需要考虑 react-native,那么除了以下两步:

  1. 引入 babel-plugin-import
  2. 引入 postcss-plugin-px2rem, ref

还有啥?

@afc163
Copy link
Member

afc163 commented Nov 17, 2016

@paranoidjk
Copy link

paranoidjk commented Jun 30, 2017

ref: dvajs/dva-cli#98

dva-cli, antd-init both need to support antd-mobile

@paranoidjk paranoidjk assigned paranoidjk and unassigned sorrycc and afc163 Jun 30, 2017
@CHENJIADI01
Copy link

how to install router for antd-init?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants