s-stage.vue

0.1.1 • Public • Published

SStage 阶段

阶段组件

示例

基本用法

<template>
<s-stage :list="list" @add="addStage"></s-stage>
</template>

<script>
export default {
	data(){
		return {
			list: [{ name: 'step 1' }, { name: 'step 2' }],
		}
	},
    methods: {
        addStage(index) {
            this.list.splice(index, 0, { name: 'new step' });
        }
    }
}
</script>

API

Props/Attrs

Prop/Attr Type Options Default Description
list Array [] 需要传入的值

Slots

(default)

插入文本或 HTML。

Events

@add

新增时触发

Param Type Description
$event.index string 参数1

@remove

删除时触发

Param Type Description
$event.index string 参数1

@detail

点击阶段时触发

Param Type Description
$event.index string 参数1

Package Sidebar

Install

npm i s-stage.vue

Weekly Downloads

1

Version

0.1.1

License

MIT

Unpacked Size

1.9 MB

Total Files

28

Last publish

Collaborators

  • xinhua_zou