{"dist":{"shasum":"fc1b5cb1c7f047bd512fb37a05c1e181b02c6e91","tarball":"https://registry.npmjs.org/jsx2mp-runtime/-/jsx2mp-runtime-0.4.4-2.tgz","fileCount":4,"integrity":"sha512-tqVLZxOPwP4kvA4KaeSpy7DSiJEdPhQgWhZoyPsTNiJkJT81Grn2ocQ15OsMgJJ2ulqZUMHSe8kxbmY3PP0NRA==","signatures":[{"sig":"MEYCIQDkUDEsGfZSIN23FmIMD1DrCiaqLDk7TjOl+32jwG3RxQIhAPe0mYLRGRhb3cp0B0FePLsMfnlObuZMz7NEcVK1BP4Y","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":90450,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJeeNRcCRA9TVsSAnZWagAAsaQP/2F0kBU/ZoffMjrPdXxc\ny27wdSiuSyzJaxoV49NsuXK2E0yNXGBYwYltQVzweyXhfsdlkiYpuLyGdoVY\nWazs8LduRu5GDLWSYEuUqHVNPiyR/tOy4N5KHO32y5LRmV7W9jOewk3pL6Dv\nAlZkq/N4j5T3qSsg7kqDKvAZnazu2uyoMBvkTBSSStWFFqZXR0iQXmFzuOR7\nLo1n765r+fK2dk17CKmZfxsgaTKg66wyO6x+ZCOVSNMOqgd11XLRiAPgH6KJ\nXYP5AB31YWf80GmIPB6+mtLzLGLHogbfN9wyRyI1FmzttYfA2CCPY6dA9zST\ncUfcr9Sbmrrw7MhOjAM3XO2B1yiU/8RiRDGdfRH5Ji+8A2E56XRnAOCxt2Bx\nL8eFZIGG1cvwT1dO0uXB/sGbnly+xnhTAt9AGhjYeJlTkD7NAOcmpAOuDBmp\nFsz6f4zg9smZfMZJMdmrOBsQ0pR7bNb4lR4q7+eD5JBFTGs5A8MRmzL+ML/t\nPnz3Vghi6IlGQwBiN4f9bBO0nGGBGFvOYKwZqQ1dqApoC/XHguLacRxY5EgS\nKotnK6CADCwrYP4Z1Psb2v0dcCZdFA/CwabKzQQHQsJmZCqzY0vznd4/JaPv\nqugyJuzrF1enZPySkl2SIjBIRchDzOnEBYPE03404LUYdhe/bsgWvR/MCsOQ\nzqF/\r\n=SMdM\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"},"_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.4-2_1584976988264_0.2803709003631083","host":"s3://npm-registry-packages"},"_id":"jsx2mp-runtime@0.4.4-2","version":"0.4.4-2"}