Git Product home page Git Product logo

chrome-extension-starter's Introduction

Chrome Extension Starter

基于 Vue3 + TypeScript + Manifest V3 的入门项目,使创建 Chrome 扩展变得非常容易 .

使用

git clone https://github.com/cgxqd/chrome-extension-starter.git YOURFOLDERNAME
cd YOURFOLDERNAME

# Run npm install and write your library name when asked. That's all!
npm install

目录结构

|-- chrome-extension-starter
    |-- gulpfile.mjs                // 热更新逻辑
    |-- public
    |   |-- manifest.json           // 扩展配置文件
    |   |-- assets                  // 静态资源
    |-- src
        |-- background.ts           // 后台脚本
        |-- content_script.ts       // 注入html脚本
        |-- devtools                // 控制面板配置页面
        |   |-- index.html
        |   |-- main.ts
        |-- helper                  // 帮助
        |   |-- index.html
        |-- options                 // 选项页面
        |   |-- App.vue
        |   |-- index.html
        |   |-- main.ts
        |-- panel                   // 控制面板页面
        |   |-- App.vue
        |   |-- index.html
        |   |-- main.ts
        |-- popup                   // 扩展程序弹层页面
        |   |-- App.vue
        |   |-- index.html
        |   |-- main.ts
        |-- tools                   // 内置工具函数
            |-- index.ts
            |-- tool.type.ts

开始编码! 已经为您设置了 package.json 和入口文件,只需保持这些文件的名称相同即可。

特征

  • 零设置. 😉
  • 热更新 使用 Gulp + Ws 模块实现
  • Vite 用于遵循标准约定 Tree Shaking 的多个优化捆绑包
  • PrettierESLint 用于代码格式和一致性
  • git 挂钩 使用 CommitizenHusky

NPM 命令

  • npm start: 以监听方式启动项目
  • npm run build: 打包项目
  • npm run lint: Lints code

Git Hooks

遵循 COMMIT 规范的 提交消息

已经设置了预提交和提交钩子,用于使用 Prettier 格式化代码 和 ESLint 代码检查 💅

安装 commitizen 辅助生成标准化规范

npm install -g commitizen

chrome-extension-starter's People

Contributors

cgxqd avatar

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.