{"dist":{"shasum":"8c11fd72453ae850eefa7df8e20558c7af98ef64","tarball":"https://registry.npmjs.org/jsx2mp-runtime/-/jsx2mp-runtime-0.4.6-1.tgz","fileCount":5,"integrity":"sha512-ISDvKGOICsWjTIdbVGUsI2Wo080JPVD2pWGsNo6kcokXvHQh9udxiKXJnD7I07py0BSwXsGL0L3/hLfOB2/MSQ==","signatures":[{"sig":"MEQCIC1dsj39q3ha4UVP59rKoVR9/yLVTH+O7wzh6SljWxCdAiAT46dY/Wsd6coxjZ5tPF9fKU3g1wD+/IGOlWIJ5X3KEw==","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":137395,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJehAUMCRA9TVsSAnZWagAAR6oP/2kemXIjpMSW6Tj1/uk7\nuxInkmw5/6nu4h0ET2aiNBy2O4QMQ9WTmFCY7papzDq5Nt78LZen2/AFxJOG\nO0INRZxmmKaaoodkvRQGkVdIuICBgy8PufsJsil3xQUT0sXq+VKJu4UZ+4I+\nVRF2SnupSUMQWCcTBylDuECPEAFgnZ33/5BLmQwD2EqdaBNJtuCBiKYqpvJ/\nkNcGxgaB07Xvb/ZQnYSx4Z67vT3l6s+kBLrnngm58yShyqjfGDIr/Qho57GP\nWwh8R/GcVUvS7IF7i2gcmA5RVN3k0v3WMSaT8J6h+sZV2FWGufoJRb+Igy6R\nQPWKg/tzdDvvLEvZ8Szv1M5f//AEMX7ztCV2xeOFn8/q8R9ws/AifvPYxS94\nkqKwWm/9+xKnnfZndiGM67/zLjyP4F9w+TQ8pD+7s+k/cb/Npk5f1hoIrudu\nJbgmI03o4zp+aKBCmFvEJLYFA4/C3vTP+zHodEtfR5IwlrEDeHWRitCXBuQh\nMYGWZjgY7HNxxs9t/e129ltBcR73/sG515HgyBsWsa11duH2rcs7A88k89GI\n0FylqiqcIvuj3LONB/bBt/5Jy2LjfcqcE52LazlphfjlNk/pz7EnP1LD8Nxt\np2uwadZEuZViWf1r1oQkRwa3sSN0p39yvglnXKlo7umTTDpmL4nlYNuElRS9\nIwY1\r\n=sVbc\r\n-----END PGP SIGNATURE-----\r\n"},"name":"jsx2mp-runtime","author":{"name":"Rax Team"},"readme":"# jsx2mp-runtime\n\nProvide runtime support for rax style miniapp.\n\n- createComponent\n   ```js\n   const __class_def__ = class {\n     state = {\n       name: 'Rax'\n     };\n   \n     handleTap() {\n       this.setState({\n         name: 'MiniApp'\n       });\n     }\n   };\n   \n   const config = createComponent(__class_def__, 'class');\n\n  Component(config);\n  ```\n- (state) useState(defaultValue, key)\n  ```js\n  const __fn_def__ = function Header(props) {\n    const [name, setName] = useState('World', 'name');\n    const [count, setCount] = useState(0, 'count');\n  \n    return {\n      handleClick() {\n        setName('Rax');\n        setCount(count + 1);\n      }\n    }\n  };\n  \n  const config = createComponent(__fn_def__, 'function');\n  Component(config);\n  ```\n- (void) useEffect(callback)\n  ```js\n  const __fn_def__ = function Header(props) {\n    const [name, setName] = useState('World', 'name');\n    useEffect(() => {\n      console.log('didMount');\n  \n      return function unmount() {\n        console.log('unmount');\n      };\n    }, []);\n  \n    return {\n      handleClick: () => {\n        setName('Rax');\n      },\n    };\n  };\n  \n  const config = createComponent(__fn_def__, 'function');\n  Component(config);\n  ```\n","scripts":{"build":"cross-env NODE_ENV=production rollup -c rollup.config.js","prepublish":"npm run build"},"_npmUser":{"name":"solojiang","email":"feifeishen1996@gmail.com"},"_npmVersion":"6.10.3","description":"Runtime for jsx2mp.","directories":{},"maintainers":[{"name":"chriscindy","email":"yxy0919@foxmail.com"},{"name":"likai757","email":"likai757@gmail.com"},{"name":"rax-publisher","email":"rax-public@alibaba-inc.com"},{"name":"solojiang","email":"feifeishen1996@gmail.com"},{"name":"zeroling","email":"wssgcg1213@qq.com"}],"miniprogram":{"ali":"dist/jsx2mp-runtime.ali.esm.js","wechat":"dist/jsx2mp-runtime.wechat.esm.js","quickapp":"dist/jsx2mp-runtime.quickapp.esm.js"},"_nodeVersion":"10.16.0","_hasShrinkwrap":false,"readmeFilename":"README.md","devDependencies":{"rollup":"^1.13.1","cross-env":"^5.2.0","@babel/core":"^7.4.5","@babel/types":"^7.8.3","universal-env":"^3.0.0","@babel/preset-env":"^7.4.5","rollup-plugin-babel":"^4.3.2","rollup-plugin-cleanup":"^3.1.1","rollup-plugin-replace":"^2.2.0","rollup-plugin-filesize":"^6.1.0","@babel/plugin-proposal-class-properties":"^7.5.5"},"_npmOperationalInternal":{"tmp":"tmp/jsx2mp-runtime_0.4.6-1_1585710348518_0.736575728239699","host":"s3://npm-registry-packages"},"_id":"jsx2mp-runtime@0.4.6-1","version":"0.4.6-1"}