2.1.4 • Published 2 years ago

@larscom/ng-chrome-extension v2.1.4

Weekly downloads
22
License
MIT
Repository
github
Last release
2 years ago

@larscom/ng-chrome-extension

npm-release @larscom/ng-chrome-extension license npm

Easily create Angular Chrome Extensions (manifest v3)

The following scenarios/options are supported:

  • Popup
  • New Tab
  • Options
  • Service Worker
  • Content Page

How to install

npm install -g @larscom/ng-chrome-extension

Start creating a new project

ng-chrome

alt text

How to use/develop

  • change directory to your newly created project
  • run npm run start
  • goto: chrome://extensions in the browser and enable 'developer mode'
  • press Load unpacked and target the folder angular/dist

The project is automatically being watched, any changes to the files will recompile the project.

NOTE: changes to the content page and service worker scripts requires you to reload the extension in chrome://extensions

alt text alt text

Build/package for production

  • update version number inside ./angular/src/manifest.json
  • run npm run build:production
  • upload extension-build.zip to the chrome webstore.

This will run a production build and will automatically zip it as a extension package in the root folder named: extension-build.zip

Debugging

Run: npm start

Go to: Developer tools (inspect popup) => Sources => webpack

You can find your source files (TypeScript) over there.

Upgrade Angular

After you have created a new project with ng-chrome and you want to update angular.

Just follow the regular upgrade guide of angular. See: https://update.angular.io/

Angular folder

This folder contains the angular source code. Each feature (popup,options,tab) lives inside its own module and gets lazily loaded.

see: ./angular/src/app/modules

Chrome folder

This folder contains the content page/service worker scripts.

2.1.4

2 years ago

2.1.3

2 years ago

2.1.2

2 years ago

2.1.1

3 years ago

2.1.0

3 years ago

2.0.4

3 years ago

2.0.3

4 years ago

2.0.2

4 years ago

2.0.1

4 years ago

2.0.0

4 years ago

1.0.10

4 years ago

1.0.8

4 years ago

1.0.7

4 years ago

1.0.6

4 years ago

1.0.5

4 years ago

1.0.4

4 years ago

1.0.3

4 years ago

1.0.2

4 years ago

1.0.1

4 years ago

1.0.0

4 years ago