Giter Club home page Giter Club logo

Comments (1)

chenxch avatar chenxch commented on June 9, 2024 1
<html>
  <head>
    <meta charset="UTF-8" />
    <meta name="viewport" content="width=device-width,initial-scale=1.0" />
    <script src="https://unpkg.com/vue@3"></script>
    <script src="//unpkg.com/@element-plus/icons-vue"></script>
    <!-- import CSS -->
    <link rel="stylesheet" href="https://unpkg.com/element-plus/dist/index.css">
    <!-- import JavaScript -->
    <script src="https://unpkg.com/element-plus"></script>
    <title>Element Plus demo</title>
  </head>
  <body>
    <div id="app">
      <el-icon><view-icon></view-icon></el-icon>
      <el-icon><chat-dot-square></chat-dot-square></el-icon>
      <el-icon><loading></loading></el-icon>
      {{ message }}
    </div>
    <script>
      const App = {
        data() {
          return {
            message: "Loading前面两个显示不出来, 不止一个图标,还有更多图标显示不出来",
          };
        },
      };
      const app = Vue.createApp(App);
      app.use(ElementPlus);
      for (const [key, component] of Object.entries(ElementPlusIconsVue)) {
        app.component(key, component)
        if(key==='View'){
          app.component('viewIcon', component)
        }
      }
      app.mount("#app");
    </script>
  </body>
</html>
  • 使用串式闭标签写法
  • view因为和原生view标签重名,需要注册时候给它改个名字

from element-plus.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.