@marcoms/make-element
Advanced tools
Comparing version 3.1.0 to 3.1.1
{ | ||
"name": "@marcoms/make-element", | ||
"version": "3.1.0", | ||
"version": "3.1.1", | ||
"description": "Create custom elements without boilerplate", | ||
@@ -5,0 +5,0 @@ "main": "build/make-element.js", |
@@ -51,3 +51,3 @@ # make-element | ||
![Counter demo](res/counter-demo.gif) | ||
![Counter demo](https://raw.githubusercontent.com/marcoms/make-element/74297415/res/counter-demo.gif) | ||
@@ -62,4 +62,8 @@ ## API | ||
Collection of properties to register for the custom element. All configuration fields (`attr`, `get`, `set`, …) are optional. | ||
Collection of properties to register for the custom element. All configuration fields (`attr`, `get`, `set`, …) are optional | ||
##### `init` | ||
Initial value of the property to use, unless the property is bound to an attribute with `attr` (e.g. `attr: 'foo'`) *and* initialized in markup (e.g. `<x-element foo="24"></x-element>`) | ||
##### `attr` | ||
@@ -73,3 +77,3 @@ | ||
A property can be initialised through markup by supplying an attribute value, but subsequent changes to the attribute will *not* flow back to the property -- binding is therefore *one-way* from property to attribute | ||
A property can be initialised through markup by supplying an attribute value, but subsequent changes to the attribute will not flow back to the property -- binding is therefore **one-way from property to attribute** | ||
@@ -100,3 +104,3 @@ ###### Example | ||
Getter function | ||
Getter function called when the property is accessed | ||
@@ -114,3 +118,3 @@ ###### Example | ||
Setter function | ||
Setter function called on every update to the property value | ||
@@ -127,3 +131,3 @@ ###### Example | ||
Function to modify a property's value before it is passed to `set()` and stored | ||
Function used to modify the property value before it is stored and passed to `set()` | ||
@@ -140,7 +144,7 @@ ###### Example | ||
Function to modify the value to store as an attribute | ||
Function used to modify the property value when storing into an attribute | ||
##### `fromAttr(val)` | ||
Function to modify the value retreived initially from the attribute | ||
Function used to modify the attribute value if the property is initialized from the attribute | ||
@@ -171,2 +175,4 @@ #### `methods` | ||
See [http://caniuse.com/#feat=shadowdomv1](http://caniuse.com/#feat=shadowdomv1) | ||
#### `template` | ||
@@ -182,3 +188,3 @@ | ||
If `template` is also defined, `template` will be used. | ||
If `template` is also defined, `template` will be used | ||
@@ -185,0 +191,0 @@ #### `cacheIds` |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
113968
212
2