V2EX = way to explore
V2EX 是一个关于分享和探索的地方
Sign Up Now
For Existing Member  Sign In
爱意满满的作品展示区。
fjc0k

前端效率工具:一个方便生成文件索引的 VSCode 插件

  •  2
     
  •   fjc0k · Apr 14, 2021 · 2353 views
    This topic created in 1852 days ago, the information mentioned may be changed or developed.

    先来看看我在实际项目中的应用

    在 components/index.ts 导出全部组件

    image

    在 assets/index.ts 导出全部图标

    image

    小程序中一键生成路由表,获取完美的类型提示

    image

    小程序中 assets/index.ts 导出全部图片地址

    image

    组件库中将分散的样式文件统一导出

    image

    以上,这真的是一个解放双手的好家伙

    只要你会基本的 javascript 语法,就可以使用 @index 生成各式文件索引需求。

    VSCode 插件市场:https://marketplace.visualstudio.com/items?itemName=JayFong.generate-index

    GitHub:https://github.com/fjc0k/vscode-generate-index

    No Comments Yet
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   4058 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 31ms · UTC 04:19 · PVG 12:19 · LAX 21:19 · JFK 00:19
    ♥ Do have faith in what you're doing.