How to use the skatejs 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 webcomponents / react-integration / test / react-wc-tests.js View on Github external
function makeReactComponent (tagName) {
        const webComponentConstructor = skate(tagName, {
          render: function (elem) {
            elem.innerHTML = '<div></div>';
            if (elem.hidden) {
              elem.firstChild.setAttribute('aria-hidden', '');
            } else {
              elem.firstChild.removeAttribute('aria-hidden');
            }
          },
          attached: function (elem) {
            elem._hidden_on_attach = elem.hidden;
          },
          properties: {
            hidden: {
              set: function (elem) {
                skate.render(elem);
              }
github skatejs / kickflip / src / api / register.js View on Github external
export default function (name, opts) {
  linkPropsToAttrsIfNotSpecified(opts.properties);
  opts.render = render(opts.render);
  return skate(name, opts);
}