@bsachref/ng-form 1.0.2 → 1.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +5 -7
- package/package.json +1 -1
package/README.md
CHANGED
@@ -1,6 +1,6 @@
|
|
1
|
-
```md
|
2
1
|
A powerful **dynamic form builder** for **Angular** using **default** **PrimeNG** or **Angular Material**, designed to create and manage forms dynamically from JSON without writing extra HTML.
|
3
2
|
|
3
|
+
```md
|
4
4
|
---
|
5
5
|
|
6
6
|
## 🌟 Features
|
@@ -27,8 +27,6 @@ Since this package relies on Angular and PrimeNG or Angular material, ensure the
|
|
27
27
|
## 🚀 Quick Start
|
28
28
|
|
29
29
|
### 2️⃣ Use in Component
|
30
|
-
template
|
31
|
-
|
32
30
|
|
33
31
|
Modify `app.component.ts`:
|
34
32
|
```ts
|
@@ -50,7 +48,7 @@ export class AppComponent {
|
|
50
48
|
{ minlength: 2 },
|
51
49
|
{ maxlength: 50 },
|
52
50
|
],
|
53
|
-
class: 'firstname
|
51
|
+
class: 'firstname',
|
54
52
|
style: { 'background-color': 'lightgray' },
|
55
53
|
value: '',
|
56
54
|
},
|
@@ -59,7 +57,7 @@ export class AppComponent {
|
|
59
57
|
type: 'email',
|
60
58
|
label: 'Email Address',
|
61
59
|
uiFramework: 'primeng',
|
62
|
-
class: 'input-class
|
60
|
+
class: 'input-class',
|
63
61
|
validators: [
|
64
62
|
{ required: true },
|
65
63
|
{ email: true },
|
@@ -99,10 +97,10 @@ export class AppComponent {
|
|
99
97
|
|
100
98
|
## 🔥 Full Example with Validations
|
101
99
|
|
102
|
-
```md
|
103
100
|
For a full example with validations, check out this [CodeSandbox](https://codesandbox.io/p/devbox/g8jy7t).
|
101
|
+
```md
|
104
102
|
```
|
105
|
-
|
103
|
+
|
106
104
|
|
107
105
|
---
|
108
106
|
|