<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1">
<title></title>
<script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"></script>
<link rel="stylesheet" href="https://unpkg.com/element-ui/lib/theme-chalk/index.css">
<script src="https://unpkg.com/element-ui/lib/index.js"></script>
</head>
<body>
<div id="app">
<template>
<el-select
ref="select"
v-model="value"
filterable
allow-create
default-first-option
@keyup.enter.native="change"
placeholder="请选择文章标签">
<el-option
v-for="item in options"
:key="item.value"
:label="
elementui select可创建数据并localStorage存储
最新推荐文章于 2024-07-29 10:06:37 发布
本文介绍了如何在ElementUI中动态创建Select选项,并利用localStorage进行数据存储,实现页面刷新后数据仍然保留的功能。详细讲解了相关代码实现和操作流程。
摘要由CSDN通过智能技术生成