---
name: RichText
title: 富文本
category: 基础内容
owner: chenxiao07
---

## 注意事项

1. ...

## 示例

```atom 基础示例
<template>
    <div class="c-container">
        <c-rich-text :nodes="nodes" @tap="onTap"></c-rich-text>
    </div>
</template>

<script type="config">
    {
        components: {
            'c-rich-text': 'components/RichText/RichText',
        },
        data: {
            nodes: [{
                name: 'div',
                attrs: {
                    class: 'div_class',
                    style: 'line-height: 60px; color: red;'
                },
                children: [{
                    type: 'text',
                    text: 'Hello&nbsp;World!'
                }]
            }]
        }
    }
</script>

<script>
    export default {
        methods: {
            onTap() {
                console.log('tap');
            }
        }
    };
</script>

```

## API
### Props


名称 | 类型 | 默认值 | 是否必选 | 描述 | 其他
--- | --- | --- | --- | --- | ----
nodes | array \| string | [] | 可选 | 节点列表 | -






