← Back

vue/no-dupe-keys warning

Disallow duplicate key names to avoid overwriting

Examples

❌  Incorrect

<script>
    export default {
        props: {
            foo: String,
        },

        computed: {
            foo: {
                get () {}
            },
        },

        data() {
            return {
                foo: null,
            };
        },

        methods: {
            foo () {},
        },
    }
</script>