ng-xtend logo ng-xtend Framework

Build extensible Angular applications with dynamic plugins. Add features at runtime, keep your core small, and let teams extend your UI safely.

Try Live Demo Try App Generator GitHub license
Why ng-xtend Features Demos Quick start Developer guide
For Angular teams Perfect when you want plug-ins, reusable render points, or dynamic UI composition.
For plugin authors Create reusable components that can register themselves and integrate with the host app.
For product owners Ship features faster by extending the application instead of rebuilding it from scratch.

Why ng-xtend?

Successful platforms like WordPress, Nextcloud, and Drupal became powerful because they were designed to be extended. ng-xtend brings that same model to Angular and TypeScript.

Instead of hard-coding every screen, ng-xtend helps you define a clean data model and expose render points where plugins can contribute the right component, action, or view.

This makes it easier to build applications that are:

Key Features

See it in Action

Coffee Bean Evaluation

A real-world example showing list, view, and edition flows powered entirely by dynamic plugins.

Coffee Bean Evaluation

Other Demos

More live demo applications are available here:

Dont-code Demo Apps

Plugin Tester

Curious about how plugins are dynamically injected? Try the dedicated tester:

Plugin tester

Quick start

If you want the shortest path to value, start here:

  1. Explore the ng-xtend-examples repository.
  2. Open the plugin tester documentation.
  3. Review the sample plugin in xt-plugin-sample.
  4. Try a live demo to understand how host and plugins work together.

How it works

The host application does not need to know its plugins at compile time. It simply defines render points and lets the runtime resolve the right extension.

  1. Configuration: a JSON configuration defines which plugins to load from which remote URLs.
  2. Registration: when a plugin loads, it registers itself and declares the types or actions it supports.
  3. Resolution: when ng-xtend encounters a specific type such as Rating or Currency, it injects the correct component from the loaded plugins.

Supported plugin types

Type Description
Simple components Turn regular Angular components into pluggable units for specific data types.
Complex components Components that provide their own extension points. Example: a Money plugin delegating Currency selection to another plugin.
List components Effortlessly display collections of objects by delegating item rendering to the right plugins.
Action handlers Add logic and actionable buttons to your UI dynamically.

News

Examples and use cases

ng-xtend is built to support real-world scenarios where several plugins collaborate together without tight coupling.

Here are screenshots of an application automatically handling list, view, and edition of complex data using ng-xtend, a dont-code application, and the default plugin and web plugin.

You can see how the different plugins work together without knowing each other. Even the host application does not know them.

List view screenshot Edit object screenshot

Getting started

Using the framework

The ng-xtend-examples repository shows many examples, from basic usage to more advanced plugin scenarios.

Repository of examples

To better understand real-world usage, explore the example projects below:

Example Description
basic-example Displays any object in various formats in a generic way.
typed-example By describing the type handled, ng-xtend supports more use cases.
plugin-example Countries and Money fields look nicer thanks to the newly added plugins.
inout-example A full list / edit / view flow is set up thanks to inputs and outputs connecting unknown components together.
store-example Edited elements are persisted between sessions thanks to the xt-store library included with ng-xtend.
advanced-type-example Showcase support for advanced types and models, like references.
dynamic-example Loads all plugins dynamically from another website using Native Federation.

Developing a plugin

We use a monorepo structure powered by Rush.

npm install -g @microsoft/rush
rush update
rush build

Detailed plugin development guide

  1. Checkout the repository ng-xtend.
  2. It’s a monorepo using the Rush build system, so run:
    npm install -g @microsoft/rush
    rush update
    rush build
  1. Use a copy of libs/xt-plugin-sample to develop your own plugins and components.
  2. Unit test your components using vitest
  3. Test your components using plugin-tester
    • More details in plugin-tester user documentation.
    • Run your plugin tester application, for example ng serve sample-tester for the sample plugin.
    • Run the xt-plugin-tester with ng serve plugin-tester in xt-plugin-tester directory.
    • In the Plugin Tester app, load your plugin by entering its URL in the Plugin url field.
    • Once loaded, go to the test screen, select your component in the second screen, and play with it.

Use plugins in my application

To use ng-xtend plugins in your own Angular application, xt-host project is a great example. It does:

    npm install xt-components xt-type xt-store
    npm install xt-plugin-default
    protected resolverService = inject(XtResolverService);
    this.resolverService.loadPlugin(url);

The plugins will register themselves automatically.

    this.resolverService.registerTypes({
      money: {
        amount: 'number',
        currency: 'currency' /** Type provided by the finance plugin **/
      },
      book: {
        name: 'string',
        publication: 'date',
        price: 'money',
        notation: 'rating' /** Type provided by the web plugin **/
      }
    });
        <h1>List of books</h1>
        <xt-render [displayMode]="LIST_VIEW" [valueType]="book" [value]="listOfBooks"></xt-render>

Or allow editing a book’s information:

        <h1>Enter your book details</h1>
        <div form="bookForm">
          <xt-render [displayMode]="FULL_EDITABLE" [valueType]="book" [formGroup]="bookForm" subName="book"></xt-render>
        </div>

For more complex scenarios, use:

       <xt-render-sub [context]="context()"></xt-render-sub>

with context() returning type information necessary to select the right component.

Roadmap

FAQ

Is ng-xtend only for Angular?

ng-xtend is designed around Angular and TypeScript, so it fits naturally into Angular applications and libraries.

Do I need to rebuild the host app when adding a plugin?

No. One of the main goals of ng-xtend is dynamic loading, so plugins can be loaded at runtime.

Can plugins work together?

Yes. Plugins can expose types, renderers, and actions that other plugins resolve dynamically.

Where should I start?

The best starting point is the examples repository, then the plugin tester docs.

Thank you

Please check my other project Dont-code. If you want to discuss the framework or suggest improvements, you can reach out at contact@ng-xtend.dev or developer@dont-code.net.