Home

Awesome

<p align="center"> <img src="https://raw.githubusercontent.com/larsroettig/create-pwa-studio-extension/main/static/starter_img.jpg"> </p>

PWA Studio extension generator

An extension generator for Magento PWA Studio includes all you need to build an amazing extension

🚀 Getting started

yarn create @larsroettig/pwa-extension 
npm init @magento/pwa
ParameterDescription
--template @yournamespace/templatecustom template for code generator
-venable verbose log for code generator
-ddebug download from node registry
<p align="center"> <img src="https://raw.githubusercontent.com/larsroettig/create-pwa-studio-extension/main/static/console.png"> </p>

Create your own templates

Via a parameter, you can define your own template --template @yournamespace/template
The code generator will copy any file from a node package. It solves and download packages via npm view --json ${packageName} for it should work for a private repository as well.

My starter template you can find here: https://github.com/larsroettig/create-pwa-studio-extension/tree/main/packages/cpse-template

:heavy_exclamation_mark: Attention by default LICENSE will be delete from your template but if you want to define LICENSE file you can use LICENSE.template

A minimal template need the following files: package.json

{
  "name": "@your-name/cpse-template",
  "author": "your-name <your-mail@domain.tdl>",
  "version": "2.0.0",
  "license": "MIT",
  "publishConfig": {
    "access": "public"
  }
}

package.json.template

{
  "name": "@larsroettig/pwa-extension-template",
  "author": "Lars Roettig <hello@larsroettig.de>",
  "version": "0.0.0",
  "main": "src/index.js",
}

Optional

.gitignore.template

node_modules