An open API service indexing awesome lists of open source software.

https://github.com/alibaba-fusion/materials

基于 icejs+fusion 的官方精品物料
https://github.com/alibaba-fusion/materials

blocks codesnippets react react-components scaffold

Last synced: about 1 year ago
JSON representation

基于 icejs+fusion 的官方精品物料

Awesome Lists containing this project

README

          

# Materials

Based on [Fusion Components](https://github.com/alibaba-fusion/next) and [ice.js Framework](https://github.com/alibaba/ice).

## Setup

```bash
$ npm run setup
```

## Develop

> See [Material Development Guide](https://ice.work/docs/materials/about) to learn more.

```bash
# block
$ cd blocks/ExampleBlock
$ npm install
$ npm run start
```

### Scaffolds

Each scaffold in the scaffolds folder is generated by a configuration file `.template/scaffold.json`, please do not manually modify the contents of the scaffold.

Generate scaffold command:

```bash
$ cd materials/
$ node scripts/generate.js fusion-design-pro
```

### Batch Publish Blocks

```bash
$ cd materials/
$ node scripts/publish-blocks.js
```

### Batch Publish Scaffolds

```bash
$ cd materials/
$ TYPE=scaffolds node scripts/publish-blocks.js
```

### Add New Material

```bash
$ iceworks add # select block|component|scaffold|page
```

## Publish

### Generate Materials Data

```bash
$ iceworks generate
```

### Publish Materials Data

```bash
# sync to fusion material center
$ iceworks sync
```