Socket
Socket
Sign inDemoInstall

vite-plugin-crx-hot-reload

Package Overview
Dependencies
85
Maintainers
1
Versions
13
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    vite-plugin-crx-hot-reload

A vite plugin to help Chrome extend hot updates.


Version published
Weekly downloads
8
decreased by-77.78%
Maintainers
1
Install size
4.76 MB
Created
Weekly downloads
 

Readme

Source

Introduce

This is a vite plugin that helps Chrome extensions to refresh automatically when files are modified in development.

Install

pnpm install vite-plugin-crx-hot-reload -D

Usage

import crxHotReload from 'vite-plugin-crx-hot-reload'

export default {
  plugins: [crxHotReload(/* plugin options */)]
}

Plugin options

port

  • Type: number
  • Default: 8181

Establish a Socket Connection. Send a message to the Chrome extension client to update when a file changes.

input

  • Type: string
  • Required : true

Manifest file for Chrome extension.

Example:

crxHotReload({
  input: './src/manifest.json'
})

Notes

  • When in a development environment, build.emptyOutDir needs to be set to false in the vite configuration file.
  • After starting the project, if the page does not refresh automatically after modifying content_scripts, you may need to refresh the page manually first.

Keywords

FAQs

Last updated on 05 Oct 2022

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc