Socket
Socket
Sign inDemoInstall

base-element

Package Overview
Dependencies
3
Maintainers
1
Versions
9
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 2.1.0 to 2.1.1

7

package.json
{
"name": "base-element",
"version": "2.1.0",
"version": "2.1.1",
"description": "An element authoring library for creating standalone and performant elements.",

@@ -28,7 +28,2 @@ "main": "index.js",

},
"browserify": {
"transform": [
"babelify"
]
},
"keywords": [

@@ -35,0 +30,0 @@ "virtual",

14

README.md

@@ -23,3 +23,4 @@ # base-element

## example usage
Create a generic JavaScript "class" that inherits BaseElement:
You can construct your element API however you choose. A way that I prefer is
by inheriting prototypes:

@@ -49,4 +50,3 @@ ```js

### Prefer just functions?
If you don't like "classes" the API supports an alternative interface with just
functions:
If you prefer just functions, an alternative interface is available:

@@ -60,3 +60,3 @@ ```js

// Render a button upon clicked will alert
return this.html('button', {
return el.html('button', {
onclick: function (e) {

@@ -116,3 +116,3 @@ window.alert(e.target.innerText + ' button was clicked')

For example if I create an `input-box` element and published on npm:
For example if you create an `input-box` element and published on npm:

@@ -139,4 +139,4 @@ ```js

Now yourself or another user can either consume your `input-box` or extend it
to add their own functionality on top of yours, such as `email-input`:
Later yourself or another user can extend `input-box` to add functionality on
top, such as `email-input`:

@@ -143,0 +143,0 @@ ```js

Sorry, the diff of this file is too big to display

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc