Skip to content

This repo make the example of how to extends a existed compoenent

Notifications You must be signed in to change notification settings

Hyperxq/schematic-component-extended-workshop

Repository files navigation

Getting Started

In this repo you will see how to extends an existed schematic, in this case the component of @schematics/angular.

Installation

To get started, you'll need to install the Schematics CLI and Project Builder CLI. You can do this via npm:

npm install -g @pbuilder/cli

Creating a Schematic

To create a new schematic library project, run:

npx @pbuilder/cli new my-schematic author-1

This command will set up the project structure for your schematics.

Executing Schematics

Testing Locally

Using Schematics CLI

To test your schematics locally using the Schematics CLI, run:

schematics [dist-collection-path]:[schematic-name] [options]

Using Verdaccio

Verdaccio is a lightweight private npm proxy registry that you can use to publish and test your schematics locally. Make sure you have Verdaccio installed and running. To publish your schematic to Verdaccio, add the following npm script to your package.json:

    "scripts": {
    "publish:verdaccio": "npm publish --registry http://localhost:4873"
    }

To publish and test your schematic:

  1. Start Verdaccio:
npx verdaccio
  1. Publish your schematic to Verdaccio:
npm run publish:verdaccio
  1. Install and execute your schematic from Verdaccio:
npm install my-schematic --registry http://localhost:4873
schematics my-schematic:my-rule

Documentation

For more detailed instructions and options, visit the Schematics Documentation.

Contributing

We welcome contributions! Please read our Contributing Guidelines for details on our code of conduct and the process for submitting pull requests.

schematic-component-extended-workshop

About

This repo make the example of how to extends a existed compoenent

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published