How to use the skatejs.prop.string function in skatejs

To help you get started, we’ve selected a few skatejs examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github micahscopes / all-around-keyboard / src / main.js View on Github external
return val*Math.PI/180;
        },
        serialize (val) {
          return val*180/Math.PI;
        }
      }),
      depth: prop.number({ attribute: true, default: 100 }),
      width: prop.number({ attribute: true, default: 500 }),
      overlapping: prop.number({ attribute: true, default: 0.5 }),
      pie: prop.boolean({attribute: true, default: false}),
      synth: prop.boolean({attribute: true, default: false}),
      transitionTime: prop.number({attribute: true, default: 750}),
      baseTone: prop.number({attribute: true, default: 32.70375}),
      baseKey: prop.number({attribute: true, default: 0}),
      leftmostKey: prop.number({attribute: true, default: 3*12}),
      keyStyle: prop.string({attribute: true})
    };
  }
  connectedCallback () {
github zzarcon / skatepark.js / packages / tags / src / index.jsx View on Github external
import {
  Component,
  h,
  prop
} from 'skatejs';
import styles from './styles';
import {define} from 'skateparkjs-core';

const deleteCode = 8;

class SKTags extends Component {
  static props = {
    delimiter: prop.string({attribute: true, default: ' '}),
    tags: prop.array({attribute: true}),
    deletion: {
      attribute: true,
      default: false
    },
    //TODO: Implement editable tags
    editable: {
      attribute: true,
      default: true
    }
  }

  renderCallback() {
    const tags = this.tags;
    const allowDeletion = this.deletion ? 'deletion' : '';
    const tagElements = tags.map(t => {