npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2025 – Pkg Stats / Ryan Hefner

yc-setting-element-plus

v0.25.5

Published

### 介绍

Downloads

130

Readme

yc-setting-element-plus

介绍

yc-setting-elment-plus 是一款针对了 element-plus 框架进行实现的配置化项目开发插件。其主要是基于 yc-config-create-setting 进行实现的,并且也对 typescript 进行了处理,它能够有效的对 element-plus 所有组件的 propsevents 进行有效的推导。

快速体验

第一步

搭建项目,并安装插件

// 安装脚手架 - 该脚手架只是单纯的让你能够快速的创建 vite + vue + typescript 项目
$ npm install yc-studio-cli -g

// 使用脚手架进行创建项目
$ yc-studio-cli init demo

// 切换目录
$ cd demo

// 开始安装依赖
$ npm install

// 安装 工具 和 UI框架
$ npm install yc-setting-element-plus element-plus

第二步

App.vue 文件变更为 App.ts

内容如下

import ElSetting, { IEntity } from "yc-setting-element-plus";
// 创建一个环境信息
const ProSetting = ElSetting();
// data数据
const welcomeUseTxt = "欢迎使用 yc-setting-element-plus";
// 获取对应的工具信息
const { El, Generate, Source } = ProSetting("Test", { welcomeUseTxt });
// 函数式节点
const WelcomeTextNode: IEntity.SlotInfo<typeof Source> = (vm) =>
  vm.welcomeUseTxt;
// 输入框组件节点
const WelcomeInput = El.Input().setModel("welcomeUseTxt");
// 按钮组件节点
const ResetNode = El.Button({ type: "primary" }).setContent("重置内容").click((vm) => (vm.welcomeUseTxt = welcomeUseTxt));
// 生成组件并进行导出组件信息
export default Generate([WelcomeTextNode, WelcomeInput, ResetNode]).Component;

第三步

更改mian.ts文件内容

import { createApp } from "vue";
import App from "./App";
import ElementPlus from "element-plus";
import "./index.css";
import "./assets/scss/index.scss";
import "element-plus/dist/index.css";
const app = createApp(App);

app.use(ElementPlus);

app.mount("#app");

第四步

运行项目

$ npm run dev

开发解答

Document: 使用文档

Author:戴向天

QQ:809002582

Date: 2023-12-26