Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

ta-dom-components

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ta-dom-components - npm Package Compare versions

Comparing version 0.0.6 to 0.0.7

example/another-element.css

5

example/my-element.js
import TaDom from '/ta-dom-element.js';
import {anotherElement} from './another-element.js';

@@ -80,2 +81,3 @@ export default class MyElement extends TaDom.TaDomElement {

connectedCallback() {
super.connectedCallback();
this.mousePos$.subscribe(pos => {

@@ -138,3 +140,4 @@ this.mousePos = pos;

button({type:'button','on-click': event => this.hasThing = !this.hasThing}, 'toggle thing'),
maybeThing()
maybeThing(),
anotherElement({name:'Howard'})
)

@@ -141,0 +144,0 @@ )

4

example/my-other-element.js

@@ -6,3 +6,3 @@ import TaDom from '/ta-dom-element.js';

export default class MyOtherElement extends MyElement {
export class MyOtherElement extends MyElement {

@@ -43,2 +43,2 @@ // completely override css

TaDom.customElement('my-other-element', MyOtherElement);
export const myOtherElement = TaDom.customElement('my-other-element', MyOtherElement);
{
"name": "ta-dom-components",
"version": "0.0.6",
"version": "0.0.7",
"description": "another web-component library",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -79,2 +79,4 @@ import TaDom from '/node_modules/ta-dom/index.js';

super();
// requestAnimationFrame id
this.drawId_ = null;
// define customer getter/setters for each property

@@ -107,2 +109,5 @@ const sProps = this.constructor.properties;

this.attachShadow({mode: 'open'});
}
connectedCallback() {
// initialize state

@@ -210,3 +215,4 @@ this.setState(this.state_);

// redraw dom on next animation frame
window.requestAnimationFrame(() => {
window.cancelAnimationFrame(this.drawId);
this.drawId_ = window.requestAnimationFrame(() => {
const newDom = this.render();

@@ -213,0 +219,0 @@ if (!newDom){

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc