Coder Social home page Coder Social logo

aliraza944 / js-react-boilerplate Goto Github PK

View Code? Open in Web Editor NEW

This project forked from extend-chrome/js-react-boilerplate

0.0 0.0 0.0 220 KB

Chrome extension boilerplate with JavaScript and React

License: MIT License

JavaScript 92.54% HTML 7.46%

js-react-boilerplate's Introduction

JavaScript React Chrome Extension Boilerplate

A basic JavaScript React Chrome Extension boilerplate that gets you started quickly. It supports ES modules, JSX, and automatic reloading during development. Jest, ESLint and Prettier included, all bundled using Rollup and rollup-plugin-chrome-extension.

Get Started

Using create-react-crx

Type this into your terminal:

npx create-react-crx

Follow the prompts to setup your Chrome extension project.

Using git clone

Type this into your terminal:

git clone https://github.com/extend-chrome/js-react-boilerplate.git my-chrome-extension
cd my-chrome-extension
npm install

๐Ÿ–Œ๏ธ Update your package name and version in package.json before you get started!

Development

For development with automatic reloading:

npm run start

Open the Extensions Dashboard, enable "Developer mode", click "Load unpacked", and choose the dist folder.

When you make changes in src the background script and any content script will reload automatically.

Production

When it's time to publish your Chrome extension, make a production build to submit to the Chrome Web Store. This boilerplate will use the version in package.json, unless you add a version to src/manifest.json.

Make sure you have updated the name and version of your extension in package.json.

Run the following line:

npm run build

This will create a ZIP file with your package name and version in the releases folder.

Source Layout

Your manifest is at src/manifest.json, and Rollup will bundle any files you include here. All the filepaths in your manifest should point to files in src.

Features

  • Uses Rollup to bundle your extension
  • Chrome Extension automatic reloader
  • Jest configuration for testing

Resources

Chrome Extension official documentation

How to Publish your extension step by step video tutorial

js-react-boilerplate's People

Contributors

amysteam avatar jacksteamdev 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.