Skip to content

Commit

Permalink
Merge pull request #471 from gund/next
Browse files Browse the repository at this point in the history
[Feat] Add Angular v14 support
  • Loading branch information
gund authored Jun 16, 2022
2 parents 544ed23 + dff5e0e commit 1436eda
Show file tree
Hide file tree
Showing 20 changed files with 17,198 additions and 12,317 deletions.
2 changes: 0 additions & 2 deletions .appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,7 @@ install:
test_script:
- node --version
- npm run build
- npm run lint
- npm run test:ci
- npm run coverage:check

build: off
deploy: off
Expand Down
1 change: 0 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ jobs:
- npm run format:check
- npm run lint
- npm run test:ci
- npm run coverage:check
- npm run build
- npm run test:report
deploy:
Expand Down
21 changes: 21 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,26 @@
# ng-dynamic-component - Changelog

# [10.2.0-next.3](https://github.com/gund/ng-dynamic-component/compare/v10.2.0-next.2...v10.2.0-next.3) (2022-06-16)


### Reverts

* Revert "docs(readme): update compat table" ([b317a3e](https://github.com/gund/ng-dynamic-component/commit/b317a3e2841833683ffc28d963be090531aadf3e))

# [10.2.0-next.2](https://github.com/gund/ng-dynamic-component/compare/v10.2.0-next.1...v10.2.0-next.2) (2022-06-16)


### Bug Fixes

* **component:** add compatibility with Angular v12 to component rendering ([18c3922](https://github.com/gund/ng-dynamic-component/commit/18c3922e1ddf6b884411eaff1f821143e526a1aa)), closes [#472](https://github.com/gund/ng-dynamic-component/issues/472)

# [10.2.0-next.1](https://github.com/gund/ng-dynamic-component/compare/v10.1.0...v10.2.0-next.1) (2022-06-15)


### Features

* **ng:** add support for Angular v14+ ([451f04e](https://github.com/gund/ng-dynamic-component/commit/451f04ec7862e3c597f8c90379cbb437e631d376)), closes [#469](https://github.com/gund/ng-dynamic-component/issues/469)

# [10.1.0](https://github.com/gund/ng-dynamic-component/compare/v10.0.0...v10.1.0) (2021-12-17)


Expand Down
20 changes: 14 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,18 @@
[![semantic-release](https://img.shields.io/badge/%20%20%F0%9F%93%A6%F0%9F%9A%80-semantic--release-e10079.svg)](https://github.com/semantic-release/semantic-release)
[![Greenkeeper badge](https://badges.greenkeeper.io/gund/ng-dynamic-component.svg)](https://greenkeeper.io/)

## Compatibility with Angular

Library supports Angular `v12+` since version `v10.2.x`.

<details>
<summary>For a more detailed history see table below:</summary>

| Angular | ng-dynamic-component | NPM package |
| ------- | -------------------- | ------------------------------ |
| 14.x.x | 10.2.x | `ng-dynamic-component@^10.2.0` |
| 13.x.x | 10.x.x | `ng-dynamic-component@^10.0.0` |
| 12.x.x | 9.x.x | `ng-dynamic-component@^9.0.0` |
| 12.x.x | 10.2.x or 9.x.x | `ng-dynamic-component@^10.2.0` |
| 11.x.x | 8.x.x | `ng-dynamic-component@^8.0.0` |
| 10.x.x | 7.x.x | `ng-dynamic-component@^7.0.0` |
| 9.x.x | 6.x.x | `ng-dynamic-component@^6.0.0` |
Expand All @@ -26,6 +34,8 @@
| 4.x.x | 1.x.x | `ng-dynamic-component@^1.0.0` |
| 2.x.x | 0.x.x | `ng-dynamic-component@^0.0.0` |

</details>

## Installation

```bash
Expand Down Expand Up @@ -61,9 +71,7 @@ and bind from your component class type of component to render:
```ts
@Component({
selector: 'my-component',
template: `
<ndc-dynamic [ndcDynamicComponent]="component"></ndc-dynamic>
`,
template: ` <ndc-dynamic [ndcDynamicComponent]="component"></ndc-dynamic> `,
})
class MyComponent {
component = Math.random() > 0.5 ? MyDynamicComponent1 : MyDynamicComponent2;
Expand Down Expand Up @@ -144,7 +152,7 @@ class MyComponent {
something: () => 'can be really complex',
};
outputs = {
onSomething: type => alert(type),
onSomething: (type) => alert(type),
};
}

Expand Down Expand Up @@ -314,7 +322,7 @@ import { dynamicDirectiveDef } from 'ng-dynamic-component';
class MyComponent {
component = MyDynamicComponent1;
directiveInputs = { prop1: 'value' };
directiveOutputs = { output1: evt => this.doSomeStuff(evt) };
directiveOutputs = { output1: (evt) => this.doSomeStuff(evt) };
dirs = [
dynamicDirectiveDef(
MyDirective,
Expand Down
4 changes: 2 additions & 2 deletions angular.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@
}
}
},
"defaultProject": "ng-dynamic-component",
"cli": {
"defaultCollection": "@angular-eslint/schematics"
"schematicCollections": ["@angular-eslint/schematics"],
"analytics": false
}
}
Loading

0 comments on commit 1436eda

Please sign in to comment.