How to use the omio.rpx function in omio

To help you get started, we’ve selected a few omio 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 Tencent / omi / packages / omi-kbone / src / components / game / index.js View on Github external
define('my-game', _ => (
  <div class="game">
    {_.store.data.map.map(row =&gt; {
      return <p>
        {row.map(col =&gt; {
          if (col) {
            return <b class="s"></b>
          }
          return <b></b>
        })}
      </p>
    })}
  </div>
), {
    use: ['map'],
    css: ("undefined" != typeof wx &amp;&amp; wx.getSystemInfoSync) ? '' : rpx(require('./_index.css'))
  })
github Tencent / omi / packages / omi-kbone / src / components / index / index.js View on Github external
<div class="ctrl">
      <div class="btn cm-btn cm-btn-dir up"><i></i><em></em><span>Up</span></div>
      <div class="btn cm-btn cm-btn-dir down"><i></i><em></em><span>Down</span></div>
      <div class="btn cm-btn cm-btn-dir left"><i></i><em></em><span>Left</span></div>
      <div class="btn cm-btn cm-btn-dir right"><i></i><em></em><span>Right</span></div>
      <div class="btn cm-btn space"><i></i><span>加速/减速</span></div>
      <div class="btn reset small"><i></i><span>Reset</span></div>
      <div class="btn pp small"><i></i><span>{store.data.paused ? 'Play' : 'Pause'}</span></div>
    </div>
  
), {
    useSelf: ['paused'],
    css: ("undefined" != typeof wx &amp;&amp; wx.getSystemInfoSync) ? '' : rpx(require('./_index.css'))
  })

omio

Omi for old browsers(IE8+).

MIT
Latest version published 4 years ago

Package Health Score

58 / 100
Full package analysis